Skip to content

Commit

Permalink
insert test studies in reverse to preserve previous ordering
Browse files Browse the repository at this point in the history
  • Loading branch information
SandyRogers committed Jan 22, 2024
1 parent a036402 commit 4fd2f3d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion tests/api/test_study.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ def test_public(self, client, study, study_private):
assert d['attributes']['accession'] == "MGYS00001234"

def test_csv(self, client, studies):
url = reverse("emgapi_v1:studies-list", kwargs={'format': 'csv', 'ordering': 'last_update'})
url = reverse("emgapi_v1:studies-list", kwargs={'format': 'csv'})
response = client.get(url)
assert response.status_code == status.HTTP_200_OK
assert response.get('Content-Disposition') == 'attachment; filename="Study.csv"'
Expand Down
2 changes: 1 addition & 1 deletion tests/test_utils/emg_fixtures.py
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ def super_study(study, study_private, biome):
@pytest.fixture
def studies(biome):
studies = []
for pk in range(1, 50):
for pk in range(49, 0, -1):
studies.append(
emg_models.Study(
biome=biome,
Expand Down

0 comments on commit 4fd2f3d

Please sign in to comment.