Skip to content

Commit

Permalink
Fixing tests after reintroducing the lazy='joined' for Updates commen…
Browse files Browse the repository at this point in the history
…ts and build

Signed-off-by: Adam Saleh <asaleh@redhat.com>
  • Loading branch information
AdamSaleh committed Dec 1, 2021
1 parent b758a4c commit 526ae50
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 7 deletions.
5 changes: 3 additions & 2 deletions bodhi/tests/server/services/test_updates.py
Original file line number Diff line number Diff line change
Expand Up @@ -2938,8 +2938,9 @@ def test_list_updates_with_multiple_statuses(self):
res = self.app.get('/updates/', {"status": ["pending", "testing"]})
body = res.json_body
assert len(body['updates']) == 2
assert body['updates'][0]['title'] == 'bodhi-2.0-1.fc17'
assert body['updates'][1]['title'] == 'python-nose-1.3.7-11.fc17'
expected = ['bodhi-2.0-1.fc17', 'python-nose-1.3.7-11.fc17']
actual = sorted(update['title'] for update in body['updates'])
assert expected == actual

def test_list_updates_by_suggest(self):
res = self.app.get('/updates/', {"suggest": "unspecified"})
Expand Down
2 changes: 1 addition & 1 deletion bodhi/tests/server/tasks/test_composer.py
Original file line number Diff line number Diff line change
Expand Up @@ -526,7 +526,7 @@ def test_tag_ordering(self, *args):
compose_schemas.ComposeComposingV1.from_dict({
'repo': 'f17-updates-testing',
'ctype': 'rpm',
'updates': ['bodhi-2.0-1.fc17', 'bodhi-2.0-2.fc17'],
'updates': ['bodhi-2.0-2.fc17', 'bodhi-2.0-1.fc17'],
'agent': 'bowlofeggs'}),
update_schemas.UpdateReadyForTestingV1,
update_schemas.UpdateReadyForTestingV1,
Expand Down
2 changes: 1 addition & 1 deletion bodhi/tests/server/test_models.py
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@ def test__to_json_no_seen(self):

def test_grid_columns(self):
"""Assert correct return value from the grid_columns() method."""
assert model.Build.grid_columns() == ['nvr', 'signed', 'release_id', 'type', 'epoch']
assert sorted(model.Build.grid_columns()) == sorted(['nvr', 'signed', 'release_id', 'type', 'epoch'])

def test_find_child_for_rpm(self):
subclass = model.Package.find_polymorphic_child(model.ContentType.rpm)
Expand Down
6 changes: 3 additions & 3 deletions bodhi/tests/server/test_push.py
Original file line number Diff line number Diff line change
Expand Up @@ -202,9 +202,9 @@ def test_archived_release(self):
===== <Compose: F17 testing> =====
bodhi-2.0-1.fc17
python-nose-1.3.7-11.fc17
python-paste-deploy-1.5.2-8.fc17
bodhi-2.0-1.fc17
Push these 3 updates? [y/N]: n
Expand All @@ -215,8 +215,8 @@ def test_archived_release(self):
===== <Compose: F17 testing> =====
python-nose-1.3.7-11.fc17
ejabberd-16.09-4.fc17
python-nose-1.3.7-11.fc17
Push these 2 updates? [y/N]: y
Expand Down Expand Up @@ -295,8 +295,8 @@ def test_archived_release(self):
===== <Compose: F17 testing> =====
bodhi-2.0-1.fc17
python-paste-deploy-1.5.2-8.fc17
bodhi-2.0-1.fc17
Push these 2 updates? [y/N]: y
Expand Down

0 comments on commit 526ae50

Please sign in to comment.