diff -r 1e0235478403 -r 31a1813d53f3 web/test/unittest_urlpublisher.py --- a/web/test/unittest_urlpublisher.py Thu Dec 12 12:28:43 2013 +0100 +++ b/web/test/unittest_urlpublisher.py Thu Dec 12 12:34:38 2013 +0100 @@ -62,42 +62,42 @@ self.assertEqual(ctrl, 'view') self.assertEqual(rset.description[0][0], 'CWEType') self.assertEqual(rset.printable_rql(), - "Any X,AA,AB ORDERBY AA WHERE X is CWEType, X name AA, X modification_date AB") + "Any X,AA,AB ORDERBY AA WHERE X is_instance_of CWEType, X name AA, X modification_date AB") def test_rest_path_by_attr(self): ctrl, rset = self.process('CWUser/login/admin') self.assertEqual(ctrl, 'view') self.assertEqual(len(rset), 1) self.assertEqual(rset.description[0][0], 'CWUser') - self.assertEqual(rset.printable_rql(), 'Any X,AA,AB,AC,AD WHERE X is CWUser, X login AA, X firstname AB, X surname AC, X modification_date AD, X login "admin"') + self.assertEqual(rset.printable_rql(), 'Any X,AA,AB,AC,AD WHERE X is_instance_of CWUser, X login AA, X firstname AB, X surname AC, X modification_date AD, X login "admin"') def test_rest_path_unique_attr(self): ctrl, rset = self.process('cwuser/admin') self.assertEqual(ctrl, 'view') self.assertEqual(len(rset), 1) self.assertEqual(rset.description[0][0], 'CWUser') - self.assertEqual(rset.printable_rql(), 'Any X,AA,AB,AC,AD WHERE X is CWUser, X login AA, X firstname AB, X surname AC, X modification_date AD, X login "admin"') + self.assertEqual(rset.printable_rql(), 'Any X,AA,AB,AC,AD WHERE X is_instance_of CWUser, X login AA, X firstname AB, X surname AC, X modification_date AD, X login "admin"') def test_rest_path_eid(self): ctrl, rset = self.process('cwuser/eid/%s' % self.user().eid) self.assertEqual(ctrl, 'view') self.assertEqual(len(rset), 1) self.assertEqual(rset.description[0][0], 'CWUser') - self.assertEqual(rset.printable_rql(), 'Any X,AA,AB,AC,AD WHERE X is CWUser, X login AA, X firstname AB, X surname AC, X modification_date AD, X eid %s' % rset[0][0]) + self.assertEqual(rset.printable_rql(), 'Any X,AA,AB,AC,AD WHERE X is_instance_of CWUser, X login AA, X firstname AB, X surname AC, X modification_date AD, X eid %s' % rset[0][0]) def test_rest_path_non_ascii_paths(self): ctrl, rset = self.process('CWUser/login/%C3%BFsa%C3%BFe') self.assertEqual(ctrl, 'view') self.assertEqual(len(rset), 1) self.assertEqual(rset.description[0][0], 'CWUser') - self.assertEqual(rset.printable_rql(), u'Any X,AA,AB,AC,AD WHERE X is CWUser, X login AA, X firstname AB, X surname AC, X modification_date AD, X login "\xffsa\xffe"') + self.assertEqual(rset.printable_rql(), u'Any X,AA,AB,AC,AD WHERE X is_instance_of CWUser, X login AA, X firstname AB, X surname AC, X modification_date AD, X login "\xffsa\xffe"') def test_rest_path_quoted_paths(self): ctrl, rset = self.process('BlogEntry/title/hell%27o') self.assertEqual(ctrl, 'view') self.assertEqual(len(rset), 1) self.assertEqual(rset.description[0][0], 'BlogEntry') - self.assertEqual(rset.printable_rql(), u'Any X,AA,AB,AC WHERE X is BlogEntry, X creation_date AA, X title AB, X modification_date AC, X title "hell\'o"') + self.assertEqual(rset.printable_rql(), u'Any X,AA,AB,AC WHERE X is_instance_of BlogEntry, X creation_date AA, X title AB, X modification_date AC, X title "hell\'o"') def test_rest_path_errors(self): self.assertRaises(NotFound, self.process, 'CWUser/eid/30000')