コード例 #1
0
ファイル: test_view.py プロジェクト: Python3pkg/Flask-Z3950
 def test_next_url_constructed_when_end_not_reached(self, app):
     with app.test_request_context():
         url = view._get_next_url('q', 1, 10, 100)
         assert url == 'http://localhost/?query=q&position=11&size=10'
コード例 #2
0
 def test_next_url_not_constructed_when_end_reached(self, app):
     with app.test_request_context():
         url = view._get_next_url("q", 90, 10, 100)
         assert url is None
コード例 #3
0
ファイル: test_view.py プロジェクト: Python3pkg/Flask-Z3950
 def test_next_url_not_constructed_when_end_reached(self, app):
     with app.test_request_context():
         url = view._get_next_url('q', 90, 10, 100)
         assert url is None
コード例 #4
0
 def test_next_url_constructed_when_end_not_reached(self, app):
     with app.test_request_context():
         url = view._get_next_url("q", 1, 10, 100)
         assert url == "http://localhost/?query=q&position=11&size=10"