File tree Expand file tree Collapse file tree 3 files changed +23
-0
lines changed
tests/ert/unit_tests/scheduler Expand file tree Collapse file tree 3 files changed +23
-0
lines changed Original file line number Diff line number Diff line change @@ -1167,6 +1167,13 @@ async def test_submit_with_resource_requirement_with_bsub_capture():
1167
1167
assert "hname" not in Path ("captured_bsub_args" ).read_text (encoding = "utf-8" )
1168
1168
1169
1169
1170
+ @pytest .mark .usefixtures ("capturing_bsub" )
1171
+ async def test_empty_job_name ():
1172
+ driver = LsfDriver ()
1173
+ await driver .submit (0 , "/bin/sleep" )
1174
+ assert " -J sleep " in Path ("captured_bsub_args" ).read_text (encoding = "utf-8" )
1175
+
1176
+
1170
1177
@pytest .mark .integration_test
1171
1178
@pytest .mark .usefixtures ("use_tmpdir" )
1172
1179
async def test_submit_with_num_cpu (pytestconfig , job_name ):
Original file line number Diff line number Diff line change @@ -165,6 +165,13 @@ async def test_job_name():
165
165
assert " -Nsleepy " in Path ("captured_qsub_args" ).read_text (encoding = "utf-8" )
166
166
167
167
168
+ @pytest .mark .usefixtures ("capturing_qsub" )
169
+ async def test_empty_job_name ():
170
+ driver = OpenPBSDriver ()
171
+ await driver .submit (0 , "/bin/sleep" )
172
+ assert " -Nsleep " in Path ("captured_qsub_args" ).read_text (encoding = "utf-8" )
173
+
174
+
168
175
@pytest .mark .usefixtures ("capturing_qsub" )
169
176
async def test_job_name_with_prefix ():
170
177
driver = OpenPBSDriver (job_prefix = "pre_" )
Original file line number Diff line number Diff line change @@ -144,6 +144,15 @@ async def test_project_code_is_set(project_code):
144
144
)
145
145
146
146
147
+ @pytest .mark .usefixtures ("capturing_sbatch" )
148
+ async def test_empty_job_name ():
149
+ driver = SlurmDriver ()
150
+ await driver .submit (0 , "/bin/sleep" )
151
+ assert "--job-name=sleep" in Path ("captured_sbatch_args" ).read_text (
152
+ encoding = "utf-8"
153
+ )
154
+
155
+
147
156
@pytest .mark .usefixtures ("capturing_sbatch" )
148
157
@given (max_runtime = st .floats (min_value = 1 , max_value = 999999999 ))
149
158
async def test_max_runtime_is_properly_formatted (max_runtime ):
You can’t perform that action at this time.
0 commit comments