test: test github use_max_tag with paging and include_tags_pattern
This commit is contained in:
parent
23e9464cda
commit
2e4f2bc424
|
@ -1,7 +1,8 @@
|
|||
# MIT licensed
|
||||
# Copyright (c) 2013-2017 lilydjwg <lilydjwg@gmail.com>, et al.
|
||||
# Copyright (c) 2013-2018 lilydjwg <lilydjwg@gmail.com>, et al.
|
||||
|
||||
import os
|
||||
import re
|
||||
import pytest
|
||||
pytestmark = [pytest.mark.asyncio,
|
||||
pytest.mark.skipif("NVCHECKER_GITHUB_TOKEN" not in os.environ,
|
||||
|
@ -21,3 +22,11 @@ async def test_github_max_tag(get_version):
|
|||
|
||||
async def test_github_max_tag_with_ignored_tags(get_version):
|
||||
assert await get_version("example", {"github": "harry-sanabria/ReleaseTestRepo", "use_max_tag": 1, "ignored_tags": "second_release release3"}) == "first_release"
|
||||
|
||||
async def test_github_max_tag_with_include(get_version):
|
||||
version = await get_version("example", {
|
||||
"github": "EFForg/https-everywhere",
|
||||
"use_max_tag": 1,
|
||||
"include_tags_pattern": r"^\d",
|
||||
})
|
||||
assert re.match(r'[\d.]+', version)
|
||||
|
|
Loading…
Reference in New Issue