Commit 0c652556 authored by Nsukami Patrick's avatar Nsukami Patrick
Browse files

Flake8: fix E117 over-indented

parent 378026a043e9
......@@ -1386,25 +1386,25 @@ class EntityMapperTC(CubicWebTC):
self._check_thumbnail_relations_and_schema(mapper)
def _check_thumbnail_relations_and_schema(self, mapper):
relations = [(rtype, role)
for rtype, role, _ in mapper.relations('view')]
self.assertEqual([('data', 'subject')], relations)
relations = [(rtype, role)
for rtype, role, _ in mapper.relations('creation')]
self.assertEqual([('data', 'subject')], relations)
schema = mapper.json_schema(VIEW_ROLE)
expected = {
'title': 'Thumbnail',
'type': 'object',
'properties': {
'data': {
'title': 'data',
'type': 'string',
},
relations = [(rtype, role)
for rtype, role, _ in mapper.relations('view')]
self.assertEqual([('data', 'subject')], relations)
relations = [(rtype, role)
for rtype, role, _ in mapper.relations('creation')]
self.assertEqual([('data', 'subject')], relations)
schema = mapper.json_schema(VIEW_ROLE)
expected = {
'title': 'Thumbnail',
'type': 'object',
'properties': {
'data': {
'title': 'data',
'type': 'string',
},
'additionalProperties': False,
}
self.assertEqual(schema, expected)
},
'additionalProperties': False,
}
self.assertEqual(schema, expected)
def test_relation_targets(self):
with self.admin_access.cnx() as cnx:
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment