示例#1
0
 def test_ordered(self):
     self.assertTrue(is_ordered((1, 2, 3)))
     self.assertFalse(is_ordered((1, 3, 2)))
     self.assertTrue(is_ordered((3, 2, 1), relation=operator.gt))
示例#2
0
 def test_custom_operator(self):
     assert is_ordered((3, 2, 1), relation=operator.gt)
示例#3
0
 def test_ordered(self):
     assert is_ordered((1, 2, 3))
示例#4
0
 def test_not_ordered(self):
     assert not is_ordered((1, 3, 2))
示例#5
0
 def test_ordered(self):
     self.assertTrue(is_ordered((1, 2, 3)))
     self.assertFalse(is_ordered((1, 3, 2)))
     self.assertTrue(is_ordered((3, 2, 1), relation=operator.gt))