Пример #1
0
 def test_countif_strictly_superior(self):
     assert 3 == countif([7, 25, 13, 25], '>10')
Пример #2
0
 def test_countif_with_string_equality(self):
     self.assertEqual(countif([7, 'e', 13, 'e'], 'e'), 2)
Пример #3
0
def test_countif(value, criteria, result):
    assert countif(value, criteria) == result
Пример #4
0
 def test_countif_strictly_inferior(self):
     self.assertEqual(countif([7, 25, 13, 25], '<10'), 1)
Пример #5
0
 def test_countif_inferior(self):
     self.assertEqual(countif([7, 10, 13, 25], '<=10'), 2)
Пример #6
0
 def test_countif_with_string_inequality(self):
     assert 1 == countif([7, 'e', 13, 'f'], '>e')
Пример #7
0
 def test_argument_validity(self):
     with self.assertRaises(TypeError):
         countif(['e', 1], '>=1')
Пример #8
0
 def test_countif_superior(self):
     self.assertEqual(countif([7, 10, 13, 25], '>=10'), 3)
Пример #9
0
 def test_countif_inferior(self):
     self.assertEqual(countif([7, 10, 13, 25], '<=10'), 2)
Пример #10
0
 def test_countif_strictly_superior(self):
     self.assertEqual(countif([7, 25, 13, 25], '>10'), 3)
Пример #11
0
 def test_countif_strictly_inferior(self):
     self.assertEqual(countif([7, 25, 13, 25], '<10'), 1)
Пример #12
0
 def test_argument_validity(self):
     with self.assertRaises(TypeError):
         countif(['e', 1], '>=1')
Пример #13
0
 def test_countif_regular(self):
     assert 2 == countif(((7, 25, 13, 25), ), 25)
Пример #14
0
 def test_countif_different(self):
     assert 3 == countif(((7, 10, 13, 25), ), '<>10')
Пример #15
0
 def test_countif_superior(self):
     assert 3 == countif([7, 10, 13, 25], '>=10')
Пример #16
0
 def test_countif_different(self):
     self.assertEqual(countif([7, 10, 13, 25], '<>10'), 3)
Пример #17
0
 def test_countif_different(self):
     assert 3 == countif([7, 10, 13, 25], '<>10')
Пример #18
0
 def test_countif_with_string_equality(self):
     self.assertEqual(countif([7, 'e', 13, 'e'], 'e'), 2)
Пример #19
0
 def test_countif_inferior(self):
     assert 2 == countif(((7, 10, 13, 25), ), '<=10')
Пример #20
0
 def test_countif_regular(self):
     self.assertEqual(countif([7, 25, 13, 25], 25), 2)
Пример #21
0
 def test_countif_strictly_superior(self):
     self.assertEqual(countif([7, 25, 13, 25], '>10'), 3)
Пример #22
0
 def test_countif_strictly_superior(self):
     assert 3 == countif(((7, 25, 13, 25), ), '>10')
Пример #23
0
 def test_countif_superior(self):
     self.assertEqual(countif([7, 10, 13, 25], '>=10'), 3)
Пример #24
0
 def test_countif_strictly_inferior(self):
     assert 1 == countif(((7, 25, 13, 25), ), '<10')
Пример #25
0
 def test_countif_different(self):
     self.assertEqual(countif([7, 10, 13, 25], '<>10'), 3)
Пример #26
0
 def test_countif_superior(self):
     assert 3 == countif(((7, 10, 13, 25), ), '>=10')
Пример #27
0
 def test_countif_regular(self):
     self.assertEqual(countif([7, 25, 13, 25], 25), 2)
Пример #28
0
 def test_countif_inferior(self):
     assert 2 == countif(((7, 10, 13, 25), ), '<=10')
Пример #29
0
 def test_countif(result, criteria, values):
     assert countif(values, criteria) == result
Пример #30
0
 def test_countif_different(self):
     assert 3 == countif(((7, 10, 13, 25), ), '<>10')
Пример #31
0
 def test_countif_strictly_inferior(self):
     assert 1 == countif([7, 25, 13, 25], '<10')
Пример #32
0
 def test_countif_with_string_equality(self):
     assert 2 == countif(((7, 'e', 13, 'e'), ), 'e')
Пример #33
0
 def test_countif_inferior(self):
     assert 2 == countif([7, 10, 13, 25], '<=10')
Пример #34
0
 def test_countif_with_string_inequality(self):
     assert 1 == countif(((7, 'e', 13, 'f'), ), '>e')
Пример #35
0
 def test_countif_with_string_equality(self):
     assert 2 == countif([7, 'e', 13, 'e'], 'e')
Пример #36
0
 def test_countif_regular(self):
     assert 2 == countif(((7, 25, 13, 25), ), 25)
Пример #37
0
 def test_countif_regular(self):
     assert 2 == countif([7, 25, 13, 25], 25)
Пример #38
0
 def test_countif_superior(self):
     assert 3 == countif(((7, 10, 13, 25), ), '>=10')