def test_length(self): """Test that cmp_version compares by length as last resort""" self.assertTrue(vmops.cmp_version('1.2.3', '1.2.3.4') < 0)
def test_non_lexical(self): """Test that cmp_version compares non-lexically""" self.assertTrue(vmops.cmp_version('1.2.3.10', '1.2.3.4') > 0)
def test_greater_than(self): """Test that cmp_version compares a as greater than b""" self.assertTrue(vmops.cmp_version('1.2.3.5', '1.2.3.4') > 0)
def test_equal(self): """Test that cmp_version compares a as equal to b""" self.assertTrue(vmops.cmp_version('1.2.3.4', '1.2.3.4') == 0)
def test_less_than(self): """Test that cmp_version compares a as less than b""" self.assertTrue(vmops.cmp_version('1.2.3.4', '1.2.3.5') < 0)