tests: use explicit sort to get first snapshot

This commit is contained in:
Frédéric Péters 2020-12-29 08:29:32 +01:00
parent c38c299de3
commit 4ca787beae
1 changed files with 1 additions and 1 deletions

View File

@ -512,7 +512,7 @@ def test_workflow_snapshot_max_len(pub, size_limit):
# first one: saved
assert pub.snapshot_class.count() == 3
first_id = pub.snapshot_class.select()[0].id
first_id = pub.snapshot_class.select(order_by='id')[0].id
assert pub.snapshot_class.get(first_id).object_type == 'formdef'
assert pub.snapshot_class.get(first_id + 1).object_type == 'workflow'
assert pub.snapshot_class.get(first_id + 1).object_id == '1'