Skip to content

Commit

Permalink
Update test to expect empty df instead of KeyError
Browse files Browse the repository at this point in the history
  • Loading branch information
Yngve S. Kristiansen committed May 24, 2024
1 parent d5039b2 commit 01b4537
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions tests/unit_tests/test_libres_facade.py
Original file line number Diff line number Diff line change
Expand Up @@ -187,11 +187,12 @@ def test_summary_collector(
snapshot.assert_match(data.iloc[:4].to_csv(), "summary_collector_3.csv")
assert data.shape == (200, 2)
non_existing_realization_index = 150
with pytest.raises(KeyError):
_ = snake_oil_default_storage.load_all_summary_data(
["WWCT:OP1", "WWCT:OP2"],
realization_index=non_existing_realization_index,
)
summary_data = snake_oil_default_storage.load_all_summary_data(
["WWCT:OP1", "WWCT:OP2"],
realization_index=non_existing_realization_index,
)

assert summary_data.empty


def test_misfit_collector(snake_oil_case_storage, snake_oil_default_storage, snapshot):
Expand Down

0 comments on commit 01b4537

Please sign in to comment.