Skip to content

Commit

Permalink
Merge pull request #2469 from cta-observatory/test_ci
Browse files Browse the repository at this point in the history
Fix CI after pytest-xdist update
  • Loading branch information
maxnoe committed Nov 22, 2023
2 parents bf51ad3 + b0de499 commit c05b493
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion ctapipe/core/tests/test_provenance.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,15 @@


@pytest.fixture
def provenance():
def provenance(monkeypatch):
# the singleton nature of Provenance messes with
# the order-independence of the tests asserting
# the provenance contains the correct information
# so we monkeypatch back to an empty state here
prov = Provenance()
monkeypatch.setattr(prov, "_activities", [])
monkeypatch.setattr(prov, "_finished_activities", [])

prov.start_activity("test1")
prov.add_input_file("input.txt")
prov.add_output_file("output.txt")
Expand Down

0 comments on commit c05b493

Please sign in to comment.