diff --git a/tests/tape_tests/data/object/test_object2.parquet b/tests/tape_tests/data/object/test_object2.parquet new file mode 100644 index 00000000..9f5fac64 Binary files /dev/null and b/tests/tape_tests/data/object/test_object2.parquet differ diff --git a/tests/tape_tests/data/source/test_source2.parquet b/tests/tape_tests/data/source/test_source2.parquet new file mode 100644 index 00000000..e6697d4f Binary files /dev/null and b/tests/tape_tests/data/source/test_source2.parquet differ diff --git a/tests/tape_tests/test_ensemble.py b/tests/tape_tests/test_ensemble.py index 147d14b5..a389c10d 100644 --- a/tests/tape_tests/test_ensemble.py +++ b/tests/tape_tests/test_ensemble.py @@ -2054,11 +2054,24 @@ def my_mean(flux, time, dup_time, band): @pytest.mark.parametrize("on", [None, ["ps1_objid", "filterName"], ["filterName", "ps1_objid"]]) @pytest.mark.parametrize("func_label", ["mean", "bounds"]) -def test_batch_by_band(parquet_ensemble, func_label, on): +def test_batch_by_band(func_label, on): """ Test that ensemble.batch(by_band=True) works as intended. """ + # TODO(wbeebe): This is a temporary workaround for https://github.com/lincc-frameworks/tape/issues/434 to avoid contention when reading data + # from the test files in parallel. This is the same as `parquet_ensemble` but uses copies of the parquet files referenced there. + parquet_ensemble = Ensemble(client=False) + parquet_ensemble.from_parquet( + "tests/tape_tests/data/source/test_source2.parquet", + "tests/tape_tests/data/object/test_object2.parquet", + id_col="ps1_objid", + time_col="midPointTai", + band_col="filterName", + flux_col="psFlux", + err_col="psFluxErr", + ) + if func_label == "mean": def my_mean(flux):