Exemple #1
0
 def test_constants(self):
     cases = ((1,),
              (2,),
              (3,))
     xs = case_runner(foo3_scalar, ('a', 'b', 'c'), cases,
                      constants={'b': 10, 'c': 100})
     assert xs == (111, 112, 113)
Exemple #2
0
 def test_split(self):
     cases = ((1, 10, 100),
              (2, 20, 200),
              (3, 30, 300))
     a, b = case_runner(foo3_float_bool, ('a', 'b', 'c'), cases, split=True)
     assert a == (111, 222, 333)
     assert b == (False, True, False)
 def test_constants(self):
     cases = ((1, ), (2, ), (3, ))
     xs = case_runner(foo3_scalar, ('a', 'b', 'c'),
                      cases,
                      constants={
                          'b': 10,
                          'c': 100
                      })
     assert xs == (111, 112, 113)
 def test_single_args(self):
     cases = (1, 2, 3)
     xs = case_runner(foo3_scalar,
                      'a',
                      cases,
                      constants={
                          'b': 10,
                          'c': 100
                      })
     assert xs == (111, 112, 113)
Exemple #5
0
 def test_single_args(self):
     cases = (1, 2, 3)
     xs = case_runner(foo3_scalar, 'a', cases,
                      constants={'b': 10, 'c': 100})
     assert xs == (111, 112, 113)
Exemple #6
0
 def test_parallel(self):
     cases = ((1, 10, 100),
              (2, 20, 200),
              (3, 30, 300))
     xs = case_runner(foo3_scalar, ('a', 'b', 'c'), cases, num_workers=1)
     assert xs == (111, 222, 333)
Exemple #7
0
 def test_progbar(self):
     cases = ((1, 10, 100),
              (2, 20, 200),
              (3, 30, 300))
     xs = case_runner(foo3_scalar, ('a', 'b', 'c'), cases, verbosity=2)
     assert xs == (111, 222, 333)
 def test_split(self):
     cases = ((1, 10, 100), (2, 20, 200), (3, 30, 300))
     a, b = case_runner(foo3_float_bool, ('a', 'b', 'c'), cases, split=True)
     assert a == (111, 222, 333)
     assert b == (False, True, False)
 def test_parallel(self):
     cases = ((1, 10, 100), (2, 20, 200), (3, 30, 300))
     xs = case_runner(foo3_scalar, ('a', 'b', 'c'), cases, num_workers=1)
     assert xs == (111, 222, 333)
Exemple #10
0
 def test_progbar(self):
     cases = ((1, 10, 100), (2, 20, 200), (3, 30, 300))
     xs = case_runner(foo3_scalar, ('a', 'b', 'c'), cases, verbosity=2)
     assert xs == (111, 222, 333)