cubicweb/server/test/unittest_rqlannotation.py
changeset 12237 2dd0dcb2e5f9
parent 12055 6672f51d8268
child 12885 194e9ae964ed
equal deleted inserted replaced
12236:75a6b2f40c44 12237:2dd0dcb2e5f9
     1 # -*- coding: iso-8859-1 -*-
     1 # -*- coding: iso-8859-1 -*-
     2 # copyright 2003-2016 LOGILAB S.A. (Paris, FRANCE), all rights reserved.
     2 # copyright 2003 LOGILAB S.A. (Paris, FRANCE), all rights reserved.
     3 # contact http://www.logilab.fr/ -- mailto:contact@logilab.fr
     3 # contact http://www.logilab.fr/ -- mailto:contact@logilab.fr
     4 #
     4 #
     5 # This file is part of CubicWeb.
     5 # This file is part of CubicWeb.
     6 #
     6 #
     7 # CubicWeb is free software: you can redistribute it and/or modify it under the
     7 # CubicWeb is free software: you can redistribute it and/or modify it under the
    29         handler.build_db_cache()
    29         handler.build_db_cache()
    30         repo, _cnx = handler.get_repo_and_cnx()
    30         repo, _cnx = handler.get_repo_and_cnx()
    31         self.__class__.repo = repo
    31         self.__class__.repo = repo
    32         super(SQLGenAnnotatorTC, self).setUp()
    32         super(SQLGenAnnotatorTC, self).setUp()
    33 
    33 
    34     def get_max_eid(self):
       
    35         # no need for cleanup here
       
    36         return None
       
    37 
       
    38     def cleanup(self):
       
    39         # no need for cleanup here
       
    40         pass
       
    41 
       
    42     def test_0_1(self):
    34     def test_0_1(self):
    43         with self.admin_access.cnx() as cnx:
    35         with self.admin_access.cnx() as cnx:
    44             rqlst = self._prepare(cnx, 'Any SEN,RN,OEN WHERE X from_entity SE, '
    36             rqlst = self._prepare(cnx, 'Any SEN,RN,OEN WHERE X from_entity SE, '
    45                                   'SE eid 44, X relation_type R, R eid 139, '
    37                                   'SE eid 44, X relation_type R, R eid 139, '
    46                                   'X to_entity OE, OE eid 42, R name RN, SE name SEN, '
    38                                   'X to_entity OE, OE eid 42, R name RN, SE name SEN, '