forked from dmwm/WMCore
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[py2py3] JobSubmitter_t.py - fix pickle path - test
- Loading branch information
1 parent
6ca003d
commit 60f6cae
Showing
2 changed files
with
7 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -16,13 +16,13 @@ class TestWorkloadFactory(object): | |
Stamp out test workfloads. | ||
""" | ||
def createWorkload(self): | ||
def createWorkload(self, name="TestWorkload"): | ||
""" | ||
_createWorkload_ | ||
Create a new workload. | ||
""" | ||
workload = newWorkload("TestWorkload") | ||
workload = newWorkload(name) | ||
workload.setOwner("[email protected]") | ||
workload.setStartPolicy("DatasetBlock", SliceType = "NumberOfFiles", SliceSize = 1) | ||
workload.setEndPolicy("SingleShot") | ||
|
@@ -119,15 +119,15 @@ def addOutputModule(self, parentTask, outputModuleName, dataTier, filterName): | |
mergedLFNBase = "/store/temp/WMAgent/merged") | ||
return | ||
|
||
def __call__(self, emulation = False): | ||
def __call__(self, name="TestWorkload", emulation=False): | ||
""" | ||
_call_ | ||
Create a test workload. | ||
""" | ||
self.emulation = emulation | ||
|
||
workload = self.createWorkload() | ||
workload = self.createWorkload(name) | ||
procTask = workload.newTask("ReReco") | ||
|
||
self.setupProcessingTask(procTask) | ||
|
@@ -136,14 +136,14 @@ def __call__(self, emulation = False): | |
self.addOutputModule(procTask, "TestOutputModule", "RECO", "SomeFilter") | ||
return workload | ||
|
||
def testWorkload(emulation = False): | ||
def testWorkload(name="TestWorkload", emulation=False): | ||
""" | ||
_testWorkflow_ | ||
Instantiate the TestWorkloadFactory and create a workload. | ||
""" | ||
myTestWorkloadFactory = TestWorkloadFactory() | ||
return myTestWorkloadFactory(emulation = emulation) | ||
return myTestWorkloadFactory(name=name, emulation=emulation) | ||
|
||
if __name__ == "__main__": | ||
testWorkload() |