Skip to content

Commit 749e0a9

Browse files
committed
REF just clobber all source code output
1 parent 61cd87d commit 749e0a9

File tree

2 files changed

+32
-2
lines changed

2 files changed

+32
-2
lines changed

docker/run_bot_task.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,6 @@ def _run_bot_task(func, *, log_level, existing_feedstock_node_attrs, **kwargs):
108108
try:
109109
with (
110110
redirect_stdout(sys.stderr),
111-
wurlitzer.pipes(stdout=sys.__stderr__),
112111
tempfile.TemporaryDirectory() as tmpdir,
113112
pushd(tmpdir),
114113
):
@@ -155,7 +154,7 @@ def _provide_source_code():
155154
output_source_code = "/cf_tick_dir/source_dir"
156155
os.makedirs(output_source_code, exist_ok=True)
157156

158-
with provide_source_code_local(recipe_dir) as cb_work_dir:
157+
with wurlitzer.pipes(), provide_source_code_local(recipe_dir) as cb_work_dir:
159158
chmod_plus_rwX(cb_work_dir, recursive=True, skip_on_error=True)
160159
sync_dirs(
161160
cb_work_dir, output_source_code, ignore_dot_git=True, update_git=False

tests/test_container_tasks.py

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -507,6 +507,37 @@ def test_container_tasks_provide_source_code_containerized(use_containers):
507507
assert "pyproject.toml" in os.listdir(source_dir)
508508

509509

510+
@pytest.mark.skipif(
511+
not (HAVE_CONTAINERS and HAVE_TEST_IMAGE), reason="containers not available"
512+
)
513+
def test_container_tasks_provide_source_code_containerized_patches(use_containers):
514+
with (
515+
tempfile.TemporaryDirectory() as tmpdir,
516+
pushd(tmpdir),
517+
):
518+
subprocess.run(
519+
[
520+
"git",
521+
"clone",
522+
"https://github.com/conda-forge/tiledb-feedstock.git",
523+
]
524+
)
525+
with pushd("tiledb-feedstock"):
526+
subprocess.run(
527+
[
528+
"git",
529+
"checkout",
530+
"2.23.x",
531+
]
532+
)
533+
534+
with provide_source_code_containerized("tiledb-feedstock/recipe") as source_dir:
535+
assert os.path.exists(source_dir)
536+
assert os.path.isdir(source_dir)
537+
assert "tiledb" in os.listdir(source_dir)
538+
assert "CMakeLists.txt" in os.listdir(source_dir)
539+
540+
510541
@pytest.mark.skipif(
511542
not (HAVE_CONTAINERS and HAVE_TEST_IMAGE), reason="containers not available"
512543
)

0 commit comments

Comments
 (0)