Example #1
0
 def test_upwward_inflection_at_third_position_should_return_3(self):
     self.assertEqual(morph.findInflection([3, 2, 1, 4]), 3)
Example #2
0
 def test_upwward_inflection_at_second_position_should_return_2(self):
     self.assertEqual(morph.findInflection([1, 0, 1]), 2)
Example #3
0
 def test_downward_inflection_at_third_position_should_return_3(self):
     self.assertEqual(morph.findInflection([1, 2, 3, 0]), 3)
Example #4
0
 def test_two_element_vector_should_return_none(self):
     self.assertIsNone(morph.findInflection([4, 3]))
Example #5
0
 def test_decreasing_vector_should_return_none(self):
     self.assertIsNone(morph.findInflection([3, 2, 1]))
Example #6
0
 def test_upwward_inflection_at_third_position_should_return_3(self):
     self.assertEqual(morph.findInflection([3, 2, 1, 4]), 3)
Example #7
0
 def test_empty_vector_should_return_none(self):
     self.assertIsNone(morph.findInflection([]))
Example #8
0
 def test_downward_inflection_at_third_position_should_return_3(self):
     self.assertEqual(morph.findInflection([1, 2, 3, 0]), 3)
Example #9
0
 def test_upwward_inflection_at_second_position_should_return_2(self):
     self.assertEqual(morph.findInflection([1, 0, 1]), 2)
Example #10
0
 def test_decreasing_vector_should_return_none(self):
     self.assertIsNone(morph.findInflection([3, 2, 1]))
Example #11
0
 def test_two_element_vector_should_return_none(self):
     self.assertIsNone(morph.findInflection([4, 3]))
Example #12
0
 def test_empty_vector_should_return_none(self):
     self.assertIsNone(morph.findInflection([]))