Skip to content

Commit

Permalink
Review comment
Browse files Browse the repository at this point in the history
  • Loading branch information
oyvindeide committed Nov 27, 2024
1 parent efcd654 commit 17a76d4
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions tests/ert/unit_tests/config/test_queue_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -509,3 +509,22 @@ def test_driver_initialization_from_defaults(queue_system):
LocalDriver(**LocalQueueOptions().driver_options)
if queue_system == QueueSystem.SLURM:
SlurmDriver(**SlurmQueueOptions().driver_options)


@pytest.mark.parametrize(
"queue_system, queue_option",
(
(QueueSystem.LSF, "LSF_QUEUE"),
(QueueSystem.TORQUE, "QUEUE"),
(QueueSystem.SLURM, "PARTITION"),
),
)
def test_deprecated_queue_name_initialization(queue_system, queue_option):
with pytest.warns(
ConfigWarning, match="Deprecated .* use: QUEUE_OPTION GENERIC QUEUE_NAME"
):
ErtConfig.from_file_contents(
"NUM_REALIZATIONS 1\n"
f"QUEUE_SYSTEM {queue_system}\n"
f"QUEUE_OPTION {queue_system} {queue_option} some_name\n"
)

0 comments on commit 17a76d4

Please sign in to comment.