Skip to content

Commit

Permalink
Merge pull request #1887 from maximlion/improve-object-tests
Browse files Browse the repository at this point in the history
Picotable: Improve get_object_extra tests
  • Loading branch information
tulimaki committed May 4, 2019
2 parents 5ae849e + b4c0f78 commit 759d000
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions shuup_tests/admin/test_picotable.py
Original file line number Diff line number Diff line change
Expand Up @@ -206,6 +206,10 @@ def test_picotable_no_mobile_link_for_missing_object_url(rf, admin_user, regular
@pytest.mark.django_db
def test_picotable_get_object_extra(rf, admin_user):
pico = get_pico(rf, admin_user)
query = {"perPage": 100, "page": 1, "sort": "+id"}
data = pico.get_data(query)
for item in data["items"]:
assert item["_extra"]["extra"] # Assert extra is True
assert pico.get_object_extra(admin_user) == {"extra": True}


Expand Down

0 comments on commit 759d000

Please sign in to comment.