nvchecker/tests/test_ubuntupkg.py

35 lines
1.0 KiB
Python
Raw Permalink Normal View History

2020-08-17 08:31:59 +00:00
# MIT licensed
# Copyright (c) 2020,2024 lilydjwg <lilydjwg@gmail.com>, et al.
2020-08-17 08:31:59 +00:00
# Copyright (c) 2017 Felix Yan <felixonmars@archlinux.org>, et al.
import pytest
pytestmark = [pytest.mark.asyncio, pytest.mark.needs_net]
2020-08-17 08:31:59 +00:00
@pytest.mark.flaky
2020-08-17 08:31:59 +00:00
async def test_ubuntupkg(get_version):
v = await get_version("sigrok-firmware-fx2lafw", {
2020-08-17 08:31:59 +00:00
"source": "ubuntupkg",
})
assert v.startswith("0.1.7-")
2020-08-17 08:31:59 +00:00
@pytest.mark.flaky
2020-08-17 08:31:59 +00:00
async def test_ubuntupkg_strip_release(get_version):
assert await get_version("sigrok-firmware-fx2lafw", {
"source": "ubuntupkg",
"strip_release": True,
}) == "0.1.7"
@pytest.mark.flaky
2020-08-17 08:31:59 +00:00
async def test_ubuntupkg_suite(get_version):
assert await get_version("sigrok-firmware-fx2lafw", {
"source": "ubuntupkg",
"suite": "xenial",
}) == "0.1.2-1"
@pytest.mark.flaky
2020-08-17 08:31:59 +00:00
async def test_ubuntupkg_suite_with_paging(get_version):
assert await get_version("ffmpeg", {
"source": "ubuntupkg",
"suite": "xenial",
}) == "7:2.8.17-0ubuntu0.1"