test (e2e/cli): use max_items instead of max when retrieving blog items:
RSM `max` alone will return first (oldest) items, while `max_items` will return latest ones. As Libervia Pubsub as been fixed in this regard, tests are now fixed too.
This commit is contained in:
parent
6b2e0649a3
commit
29e76c1adb
1 changed files with 2 additions and 2 deletions
|
|
@ -176,7 +176,7 @@ class TestLiberviaCliBlog:
|
|||
li.blog.edit(_env=editor.env)
|
||||
assert len(editor.original_content) == 0
|
||||
assert editor.new_content == payload_md
|
||||
items_data = li_json.blog.get(max=1)
|
||||
items_data = li_json.blog.get(max_items=1)
|
||||
last_item = items_data[0][0]
|
||||
last_item_id = last_item['id']
|
||||
assert last_item['content'] == "content in markdown"
|
||||
|
|
@ -187,7 +187,7 @@ class TestLiberviaCliBlog:
|
|||
li.blog.edit("--last-item", _env=editor.env)
|
||||
assert editor.original_content == payload_md
|
||||
assert editor.new_content == f"{payload_md} extended"
|
||||
items_data = li_json.blog.get(max=1)
|
||||
items_data = li_json.blog.get(max_items=1)
|
||||
last_item = items_data[0][0]
|
||||
# we check that the id hasn't been modified
|
||||
assert last_item['id'] == last_item_id
|
||||
|
|
|
|||
Loading…
Reference in a new issue