Longer time limit for test_paginate_compound_keys

It was failing intermittently in Travis - see #209
This commit is contained in:
Simon Willison 2018-04-17 18:08:51 -07:00
commit aaf59db570
No known key found for this signature in database
GPG key ID: 17E2DEA2588B7F52
2 changed files with 10 additions and 4 deletions

View file

@ -1,11 +1,13 @@
from .fixtures import (
app_client,
app_client_longer_time_limit,
generate_compound_rows,
generate_sortable_rows,
)
import pytest
pytest.fixture(scope='module')(app_client)
pytest.fixture(scope='module')(app_client_longer_time_limit)
def test_homepage(app_client):
@ -387,13 +389,13 @@ def test_paginate_tables_and_views(app_client, path, expected_rows, expected_pag
assert expected_pages == count
def test_paginate_compound_keys(app_client):
def test_paginate_compound_keys(app_client_longer_time_limit):
fetched = []
path = '/test_tables/compound_three_primary_keys.json?_shape=objects'
page = 0
while path:
page += 1
response = app_client.get(path, gather_request=False)
response = app_client_longer_time_limit.get(path, gather_request=False)
fetched.extend(response.json['rows'])
path = response.json['next_url']
assert page < 100