diff --git a/tests/ert/ui_tests/gui/test_full_manual_update_workflow.py b/tests/ert/ui_tests/gui/test_full_manual_update_workflow.py index d1784c5ee46..b70b18bbd65 100644 --- a/tests/ert/ui_tests/gui/test_full_manual_update_workflow.py +++ b/tests/ert/ui_tests/gui/test_full_manual_update_workflow.py @@ -59,7 +59,8 @@ def test_manual_analysis_workflow(ensemble_experiment_has_run, qtbot): tree_view.expandAll() model = tree_view.model() - assert model is not None and model.rowCount() == 1 + assert model is not None + assert model.rowCount() == 1 assert "iter-0_1" in model.index(1, 0, model.index(0, 0)).data(0) experiments_panel.close() diff --git a/tests/ert/unit_tests/config/test_queue_config.py b/tests/ert/unit_tests/config/test_queue_config.py index 363bd25589a..b47feb4bc81 100644 --- a/tests/ert/unit_tests/config/test_queue_config.py +++ b/tests/ert/unit_tests/config/test_queue_config.py @@ -52,7 +52,8 @@ def test_project_code_is_set_when_forward_model_contains_selected_simulator( project_code = queue_config.queue_options.project_code assert project_code is not None - assert "flow" in project_code and "rms" in project_code + assert "flow" in project_code + assert "rms" in project_code @pytest.mark.parametrize("queue_system", ["LSF", "TORQUE", "SLURM"]) @@ -175,7 +176,8 @@ def test_that_overwriting_QUEUE_OPTIONS_warns( assert ( f"Overwriting QUEUE_OPTION {queue_system} {queue_system_option}: \n Old value:" " test_0 \n New value: test_1" - ) in caplog.text and ( + ) in caplog.text + assert ( f"Overwriting QUEUE_OPTION {queue_system} MAX_RUNNING: \n Old value:" " 10 \n New value: 10" ) not in caplog.text diff --git a/tests/ert/unit_tests/resources/test_shell.py b/tests/ert/unit_tests/resources/test_shell.py index 1ab9735aef6..4b23df1d7de 100644 --- a/tests/ert/unit_tests/resources/test_shell.py +++ b/tests/ert/unit_tests/resources/test_shell.py @@ -283,9 +283,11 @@ def test_that_delete_file_deletes_broken_symlinks(): delete_file("file") assert not Path("file").exists() - assert Path("link").is_symlink() and not Path("link").exists() + assert Path("link").is_symlink() + assert not Path("link").exists() delete_file("link") - assert not Path("link").is_symlink() and not Path("link").exists() + assert not Path("link").is_symlink() + assert not Path("link").exists() @pytest.mark.usefixtures("use_tmpdir") diff --git a/tests/ert/unit_tests/scheduler/test_lsf_driver.py b/tests/ert/unit_tests/scheduler/test_lsf_driver.py index b98e914ae54..7064748a99b 100644 --- a/tests/ert/unit_tests/scheduler/test_lsf_driver.py +++ b/tests/ert/unit_tests/scheduler/test_lsf_driver.py @@ -1265,7 +1265,8 @@ def mock_poll_once_by_bhist(*args, **kwargs): await poll(driver, {0}) assert "bhist is used" in caplog.text assert bhist_called - assert driver._bhist_cache and job_id in driver._bhist_cache + assert driver._bhist_cache + assert job_id in driver._bhist_cache @pytest.mark.integration_test diff --git a/tests/ert/unit_tests/scheduler/test_scheduler.py b/tests/ert/unit_tests/scheduler/test_scheduler.py index 7736dbb2998..5d96d1ec2da 100644 --- a/tests/ert/unit_tests/scheduler/test_scheduler.py +++ b/tests/ert/unit_tests/scheduler/test_scheduler.py @@ -157,7 +157,8 @@ async def test_add_dispatch_information_to_jobs_file( assert content["real_id"] == realization.iens assert content["dispatch_url"] == test_ee_uri assert content["ee_token"] == test_ee_token - assert type(content["jobList"]) == list and len(content["jobList"]) == 0 + assert type(content["jobList"]) == list + assert len(content["jobList"]) == 0 @pytest.mark.parametrize("max_submit", [1, 2, 3])