Skip to content

Commit

Permalink
Fix tests.
Browse files Browse the repository at this point in the history
  • Loading branch information
Rémy HUBSCHER committed Oct 31, 2017
1 parent af9d6f9 commit 1334c07
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 3 deletions.
1 change: 0 additions & 1 deletion pollbot/tasks/archives.py
Original file line number Diff line number Diff line change
Expand Up @@ -239,7 +239,6 @@ async def partner_repacks(product, version):
url = '{}{}/'.format(base_url, builds[0])

# Look for partner-repacks
print(url)
async with session.get(url, headers={"Accept": "application/json"}) as resp:
body = await resp.json()
dirs = sorted([p.strip('/') for p in body['prefixes']])
Expand Down
24 changes: 22 additions & 2 deletions tests/test_views.py
Original file line number Diff line number Diff line change
Expand Up @@ -355,7 +355,18 @@ async def test_candidate_archive(cli):
"status": Status.EXISTS.value,
"message": "The archive exists at "
"https://archive.mozilla.org/pub/firefox/candidates/56.0.2-candidates/build1/ "
"and all 94 locales are present for all platforms "
"and all 95 locales are present for all platforms "
"(linux-i686, linux-x86_64, mac, win32, win64)",
"link": "https://archive.mozilla.org/pub/firefox/candidates/56.0.2-candidates/build1/"
})


async def test_candidate_archive_build(cli):
await check_response(cli, "/v1/firefox/56.0.2build1/archive", body={
"status": Status.EXISTS.value,
"message": "The archive exists at "
"https://archive.mozilla.org/pub/firefox/candidates/56.0.2-candidates/build1/ "
"and all 95 locales are present for all platforms "
"(linux-i686, linux-x86_64, mac, win32, win64)",
"link": "https://archive.mozilla.org/pub/firefox/candidates/56.0.2-candidates/build1/"
})
Expand Down Expand Up @@ -390,7 +401,7 @@ async def test_release_partner_repacks(cli):
})


async def test_candidate_partner_repacks(cli):
async def test_candidate_partner_repacks_build(cli):
await check_response(cli, "/v1/firefox/56.0.2build1/archive/partner-repacks", body={
"status": Status.EXISTS.value,
"message": "partner-repacks found in https://archive.mozilla.org/pub/"
Expand All @@ -399,6 +410,15 @@ async def test_candidate_partner_repacks(cli):
})


async def test_candidate_partner_repacks(cli):
await check_response(cli, "/v1/firefox/56.0.2rc1/archive/partner-repacks", body={
"status": Status.EXISTS.value,
"message": "partner-repacks found in https://archive.mozilla.org/pub/"
"firefox/candidates/56.0.2-candidates/build1/",
"link": "https://archive.mozilla.org/pub/firefox/candidates/56.0.2-candidates/build1/"
})


async def test_beta_partner_repacks(cli):
await check_response(cli, "/v1/firefox/56.0b10/archive/partner-repacks", body={
"status": Status.EXISTS.value,
Expand Down

0 comments on commit 1334c07

Please sign in to comment.