def test_util_check_statement(self): c = "http://example.com" self.assertRaises(SubjectTypeError, util.check_statement, (c, self.p, self.o)) self.assertRaises(PredicateTypeError, util.check_statement, (self.s, c, self.o)) self.assertRaises(ObjectTypeError, util.check_statement, (self.s, self.p, c)) res = util.check_statement((self.s, self.p, self.o)) self.assertTrue(res == None)
def test_util_check_statement(self): c = "http://example.com" self.assertRaises( SubjectTypeError, util.check_statement, (c, self.p, self.o)) self.assertRaises( PredicateTypeError, util.check_statement, (self.s, c, self.o)) self.assertRaises( ObjectTypeError, util.check_statement, (self.s, self.p, c)) res = util.check_statement((self.s, self.p, self.o)) self.assert_(res == None)