Skip to content

Commit

Permalink
Update test_results.py
Browse files Browse the repository at this point in the history
PEP fixes
  • Loading branch information
talagayev authored Oct 28, 2024
1 parent cdb0ed8 commit 5d32d15
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions testsuite/MDAnalysisTests/analysis/test_results.py
Original file line number Diff line number Diff line change
Expand Up @@ -171,12 +171,12 @@ def test_all_results(self, results_0, results_1, merger, n):
for attr, merged_value in results.items():
assert_equal(merged_value, answers.get(attr), err_msg=f"{attr=}, {merged_value=}, {arr=}, {objects=}")


def test_missing_aggregator(self, results_0, results_1, merger):
original_float_lookup = merger._lookup.get("float")
merger._lookup["float"] = None

with pytest.raises(ValueError, match="No aggregation function for key='float'"):
with pytest.raises(ValueError,
match="No aggregation function for key='float'"):
merger.merge([results_0, results_1], require_all_aggregators=True)

merger._lookup["float"] = original_float_lookup

0 comments on commit 5d32d15

Please sign in to comment.