Example #1
0
 def test_expand_cronspec_eats_iterables(self):
     self.assertEqual(
         crontab._expand_cronspec(iter([1, 2, 3]), 100),
         {1, 2, 3},
     )
     self.assertEqual(
         crontab._expand_cronspec(iter([1, 2, 3]), 100, 1),
         {1, 2, 3},
     )
 def test_expand_cronspec_eats_iterables(self):
     self.assertEqual(
         crontab._expand_cronspec(iter([1, 2, 3]), 100),
         {1, 2, 3},
     )
     self.assertEqual(
         crontab._expand_cronspec(iter([1, 2, 3]), 100, 1),
         {1, 2, 3},
     )
Example #3
0
 def test_expand_cronspec_invalid_type(self):
     with self.assertRaises(TypeError):
         crontab._expand_cronspec(object(), 100)
Example #4
0
 def test_expand_cronspec_invalid_type(self):
     with pytest.raises(TypeError):
         crontab._expand_cronspec(object(), 100)
Example #5
0
 def test_expand_cronspec_eats_iterables(self):
     assert crontab._expand_cronspec(iter([1, 2, 3]), 100) == {1, 2, 3}
     assert crontab._expand_cronspec(iter([1, 2, 3]), 100, 1) == {1, 2, 3}
Example #6
0
 def test_expand_cronspec_eats_iterables(self):
     assert crontab._expand_cronspec(iter([1, 2, 3]), 100) == {1, 2, 3}
     assert crontab._expand_cronspec(iter([1, 2, 3]), 100, 1) == {1, 2, 3}