--- a/test/unittest_analyze.py Wed Feb 13 18:14:10 2019 +0100
+++ b/test/unittest_analyze.py Wed Feb 13 18:24:25 2019 +0100
@@ -93,73 +93,73 @@
self._types['Person']._specialized_by = [self._types['Student']]
self._relations = {
'eid': RelationSchema((('Person', ('Int',)),
- ('Student', ('Int',)),
- ('Company', ('Int',)),
- ('Address', ('Int',)),
- ('Eetype', ('Int',)),
+ ('Student', ('Int',)),
+ ('Company', ('Int',)),
+ ('Address', ('Int',)),
+ ('Eetype', ('Int',)),
)
),
'creation_date': RelationSchema((('Person', ('Datetime',)),
- ('Student', ('Datetime',)),
- ('Company', ('Datetime',)),
- ('Address', ('Datetime',)),
- ('Eetype', ('Datetime',)),
+ ('Student', ('Datetime',)),
+ ('Company', ('Datetime',)),
+ ('Address', ('Datetime',)),
+ ('Eetype', ('Datetime',)),
)
),
'name': RelationSchema((('Person', ('String',)),
- ('Student', ('String',)),
- ('Company', ('String',)),
+ ('Student', ('String',)),
+ ('Company', ('String',)),
)
),
'firstname': RelationSchema((('Person', ('String',)),
- ('Student', ('String',)),
+ ('Student', ('String',)),
)
),
'work_for': RelationSchema((('Person', ('Company',)),
- ('Student', ('Company',)),
+ ('Student', ('Company',)),
),
- card='?*'),
+ card='?*'),
'is': RelationSchema((('Person', ('Eetype',)),
- ('Student', ('Eetype',)),
- ('Company', ('Eetype',)),
- ('Address', ('Eetype',)),
- ('Eetype', ('Eetype',)),
+ ('Student', ('Eetype',)),
+ ('Company', ('Eetype',)),
+ ('Address', ('Eetype',)),
+ ('Eetype', ('Eetype',)),
)
),
'is_instance_of': RelationSchema((('Person', ('Eetype',)),
- ('Student', ('Eetype',)),
- ('Company', ('Eetype',)),
- ('Address', ('Eetype',)),
- ('Eetype', ('Eetype',)),
+ ('Student', ('Eetype',)),
+ ('Company', ('Eetype',)),
+ ('Address', ('Eetype',)),
+ ('Eetype', ('Eetype',)),
)
),
'connait': RelationSchema((('Person', ('Person',)),
- ('Student', ('Person',)),
- ('Student', ('Student',)),
- ('Person', ('Student',)),
+ ('Student', ('Person',)),
+ ('Student', ('Student',)),
+ ('Person', ('Student',)),
),
- symmetric=True),
+ symmetric=True),
'located': RelationSchema((('Person', ('Address',)),
- ('Student', ('Address',)),
- ('Company', ('Address',)),
+ ('Student', ('Address',)),
+ ('Company', ('Address',)),
)
),
'owned_by': RelationSchema((('Person', ('Person',)),
- ('Student', ('Person',)),
- ('Company', ('Person',)),
- ('Eetype', ('Person',)),
+ ('Student', ('Person',)),
+ ('Company', ('Person',)),
+ ('Eetype', ('Person',)),
)
),
'identity': RelationSchema((('Person', ('Person',)),
- ('Student', ('Student',)),
- ('Company', ('Company',)),
- ('Address', ('Address',)),
- ('Eetype', ('Eetype',)),
+ ('Student', ('Student',)),
+ ('Company', ('Company',)),
+ ('Address', ('Address',)),
+ ('Eetype', ('Eetype',)),
)
),
'number': RelationSchema((('Person', ('Int',)),
- ('Student', ('Int',)),
- ('Company', ('Float',)),
+ ('Student', ('Int',)),
+ ('Company', ('Float',)),
)
),
}
--- a/test/unittest_rqlgen.py Wed Feb 13 18:14:10 2019 +0100
+++ b/test/unittest_rqlgen.py Wed Feb 13 18:24:25 2019 +0100
@@ -59,9 +59,9 @@
"""
rql = self.rql_generator.select('Person',
(('X', 'work_for', 'S'),
- ('S', 'name', '"Logilab"'),
- ('X', 'firstname', 'F'),
- ('X', 'surname', 'S')),
+ ('S', 'name', '"Logilab"'),
+ ('X', 'firstname', 'F'),
+ ('X', 'surname', 'S')),
('X',),
('F ASC', 'S DESC'))
self.assertEqual(rql, 'Person X\nWHERE X work_for S , S name "Logilab"'
@@ -72,9 +72,9 @@
"""tests the where() method behaviour
"""
rql = self.rql_generator.where((('X', 'work_for', 'S'),
- ('S', 'name', '"Logilab"'),
- ('X', 'firstname', 'F'),
- ('X', 'surname', 'S')))
+ ('S', 'name', '"Logilab"'),
+ ('X', 'firstname', 'F'),
+ ('X', 'surname', 'S')))
self.assertEqual(rql, 'WHERE X work_for S , S name "Logilab" '
', X firstname F , X surname S')