for key in varDict:
result = varexpand( "$%s" % key, varDict )
- self.failIf( result != varDict[key],
+ self.assertFalse( result != varDict[key],
msg="Got %s != %s, from varexpand( %s, %s )" % \
( result, varDict[key], "$%s" % key, varDict ) )
result = varexpand( "${%s}" % key, varDict )
- self.failIf( result != varDict[key],
+ self.assertFalse( result != varDict[key],
msg="Got %s != %s, from varexpand( %s, %s )" % \
( result, varDict[key], "${%s}" % key, varDict ) )
tests = [ ("\"${a}\"", "\"5\"") ]
for test in tests:
result = varexpand( test[0], varDict )
- self.failIf( result != test[1],
+ self.assertFalse( result != test[1],
msg="Got %s != %s from varexpand( %s, %s )" \
% ( result, test[1], test[0], varDict ) )
tests = [ ("\'${a}\'", "\'${a}\'") ]
for test in tests:
result = varexpand( test[0], varDict )
- self.failIf( result != test[1],
+ self.assertFalse( result != test[1],
msg="Got %s != %s from varexpand( %s, %s )" \
% ( result, test[1], test[0], varDict ) )
for var in testVars:
result = varexpand( "$%s" % var, varDict )
- self.failIf( len(result),
+ self.assertFalse( len(result),
msg="Got %s == %s, from varexpand( %s, %s )" \
% ( result, var, "$%s" % var, varDict ) )
result = varexpand( "${%s}" % var, varDict )
- self.failIf( len(result),
+ self.assertFalse( len(result),
msg="Got %s == %s, from varexpand( %s, %s )" \
% ( result, var, "${%s}" % var, varDict ) )
("12.2.5", "12.2b"),
]
for test in tests:
- self.failIf( vercmp( test[0], test[1] ) <= 0, msg="%s < %s? Wrong!" % (test[0],test[1]) )
+ self.assertFalse( vercmp( test[0], test[1] ) <= 0, msg="%s < %s? Wrong!" % (test[0],test[1]) )
def testVerCmpLess(self):
"""
("12.2b", "12.2.5"),
]
for test in tests:
- self.failIf( vercmp( test[0], test[1]) >= 0, msg="%s > %s? Wrong!" % (test[0],test[1]))
+ self.assertFalse( vercmp( test[0], test[1]) >= 0, msg="%s > %s? Wrong!" % (test[0],test[1]))
def testVerCmpEqual(self):
("1.0-r0", "1.0-r0"),
("1.0-r1", "1.0-r1")]
for test in tests:
- self.failIf( vercmp( test[0], test[1]) != 0, msg="%s != %s? Wrong!" % (test[0],test[1]))
+ self.assertFalse( vercmp( test[0], test[1]) != 0, msg="%s != %s? Wrong!" % (test[0],test[1]))
def testVerNotEqual(self):
("12.2b", "12.2"),
]
for test in tests:
- self.failIf( vercmp( test[0], test[1]) == 0, msg="%s == %s? Wrong!" % (test[0],test[1]))
+ self.assertFalse( vercmp( test[0], test[1]) == 0, msg="%s == %s? Wrong!" % (test[0],test[1]))