@@ -282,6 +282,42 @@ def wholeNodeJob():
282
282
return endOfAllJobs (J )
283
283
284
284
285
+ def memory_4GB ():
286
+ """simple hello world job, with a memory requirement of 4 GB and MultiProcessor tags"""
287
+
288
+ J = baseToAllJobs ("memory_4GB" )
289
+ try :
290
+ J .setInputSandbox ([find_all ("mpTest.py" , rootPath , "DIRAC/tests/Utilities" )[0 ]])
291
+ except IndexError :
292
+ try :
293
+ J .setInputSandbox ([find_all ("mpTest.py" , "." , "DIRAC/tests/Utilities" )[0 ]])
294
+ except IndexError : # we are in Jenkins
295
+ J .setInputSandbox ([find_all ("mpTest.py" , os .environ ["WORKSPACE" ], "DIRAC/tests/Utilities" )[0 ]])
296
+
297
+ J .setExecutable ("mpTest.py" )
298
+ J .setNumberOfProcessors (numberOfProcessors = 2 )
299
+ J .setTag ("4GB" )
300
+ return endOfAllJobs (J )
301
+
302
+
303
+ def memory_2_to4GB ():
304
+ """simple hello world job, with a memory requirement of 2 to 4 GB and MultiProcessor tags"""
305
+
306
+ J = baseToAllJobs ("memory_2_to_4GB" )
307
+ try :
308
+ J .setInputSandbox ([find_all ("mpTest.py" , rootPath , "DIRAC/tests/Utilities" )[0 ]])
309
+ except IndexError :
310
+ try :
311
+ J .setInputSandbox ([find_all ("mpTest.py" , "." , "DIRAC/tests/Utilities" )[0 ]])
312
+ except IndexError : # we are in Jenkins
313
+ J .setInputSandbox ([find_all ("mpTest.py" , os .environ ["WORKSPACE" ], "DIRAC/tests/Utilities" )[0 ]])
314
+
315
+ J .setExecutable ("mpTest.py" )
316
+ J .setNumberOfProcessors (numberOfProcessors = 2 )
317
+ J .setTag (["2GB" , "4GB_MAX" ])
318
+ return endOfAllJobs (J )
319
+
320
+
285
321
def parametricJob ():
286
322
"""Creates a parametric job with 3 subjobs which are simple hello world jobs"""
287
323
0 commit comments