コード例 #1
0
ファイル: Linear.py プロジェクト: ticoann/WMCore
 def __init__(self, timeout=1, max=10, unit=1):
     Basic.__init__(self, timeout, max, unit)
     self.name = "Linear"
コード例 #2
0
 def testBasicSuccesss(self):
     # This'll work on the 5th attempt
     dmy = DummyClass(5)
     # use miliseconds so the tests don't take forever...
     rty = Basic(unit=1 / 1000)
     rty.run(dmy.function)
コード例 #3
0
 def testBasicFail(self):
     # This'll work on the 15th attempt, which means the test will throw here
     dmy = DummyClass(15)
     # use miliseconds so the tests don't take forever...
     rty = Basic(unit=1 / 1000)
     self.assertRaises(RetryFailException, rty.run, dmy.function)
コード例 #4
0
ファイル: Squared.py プロジェクト: ticoann/WMCore
 def __init__(self, timeout=1, max=10, unit=1):
     Basic.__init__(self, timeout, max, unit)
     self.name = 'Squared'
コード例 #5
0
 def __init__(self, timeout=1, max=10, unit=1):
     Basic.__init__(self, timeout, max, unit)
     self.name = 'Exponential'
コード例 #6
0
ファイル: Squared.py プロジェクト: PerilousApricot/CRAB2
 def __init__(self, timeout = 1, max = 10, unit = 1):
     Basic.__init__(self, timeout, max, unit)
     self.name = 'Squared'
コード例 #7
0
ファイル: Exponential.py プロジェクト: cinquo/WMCore
 def __init__(self, timeout = 1, max = 10, unit = 1):
     Basic.__init__(self, timeout, max, unit)
     self.name = 'Exponential'
コード例 #8
0
ファイル: Basic_t.py プロジェクト: cinquo/WMCore
 def testBasicSuccesss(self):
     # This'll work on the 5th attempt
     dmy = DummyClass(5)
     # use miliseconds so the tests don't take forever...
     rty = Basic(unit = 1/1000)
     rty.run(dmy.function)