diff --git a/src/ert/shared/share/ert/forward-models/res/script/ecl_run.py b/src/ert/shared/share/ert/forward-models/res/script/ecl_run.py index 4960402ecdf..e787d81d07a 100644 --- a/src/ert/shared/share/ert/forward-models/res/script/ecl_run.py +++ b/src/ert/shared/share/ert/forward-models/res/script/ecl_run.py @@ -425,7 +425,9 @@ def summary_block(self): time.sleep(1) try: - ecl_sum = list(resfo.lazy_read(_find_unsmry(case))) + ecl_sum = [ + r.read_keyword() for r in resfo.lazy_read(_find_unsmry(case)) + ] except Exception: continue diff --git a/tests/unit_tests/shared/share/test_ecl_run.py b/tests/unit_tests/shared/share/test_ecl_run.py index 860e42191cc..cd8fc3bfd3e 100644 --- a/tests/unit_tests/shared/share/test_ecl_run.py +++ b/tests/unit_tests/shared/share/test_ecl_run.py @@ -9,7 +9,6 @@ import pytest import yaml -from resdata.summary import Summary from tests.utils import SOURCE_DIR @@ -475,7 +474,7 @@ def test_summary_block(init_ecl100_config, source_root): assert ret_value is None erun.runEclipse() - assert isinstance(erun.summary_block(), Summary) + assert erun.summary_block() is not None @pytest.mark.requires_eclipse diff --git a/tests/unit_tests/shared/share/test_ecl_run_new_config.py b/tests/unit_tests/shared/share/test_ecl_run_new_config.py index a1370b8c637..310117840d4 100644 --- a/tests/unit_tests/shared/share/test_ecl_run_new_config.py +++ b/tests/unit_tests/shared/share/test_ecl_run_new_config.py @@ -8,7 +8,6 @@ import pytest import yaml -from resdata.summary import Summary from tests.utils import SOURCE_DIR @@ -241,5 +240,4 @@ def test_summary_block(source_root): assert ret_value is None erun.runEclipse(eclrun_config=ecl_config.EclrunConfig(econfig, "2019.3")) - ecl_sum = erun.summary_block() - assert isinstance(ecl_sum, Summary) + assert erun.summary_block() is not None