mirror of
https://github.com/lilydjwg/nvchecker.git
synced 2025-03-10 06:14:02 +00:00
gitea: use the full date string as commit version
Only using the date part is too coarse. Also date could be different across timezones and thus confusing.
This commit is contained in:
parent
ad892b713e
commit
4d5e29f26b
2 changed files with 3 additions and 3 deletions
|
@ -51,7 +51,7 @@ async def get_version(
|
|||
]
|
||||
else:
|
||||
return RichResult(
|
||||
version = data[0]['commit']['committer']['date'].split('T', 1)[0].replace('-', ''),
|
||||
version = data[0]['commit']['committer']['date'],
|
||||
revision = data[0]['sha'],
|
||||
url = data[0]['html_url'],
|
||||
)
|
||||
|
|
|
@ -10,8 +10,8 @@ async def test_gitea(get_version):
|
|||
ver = await get_version("example", {
|
||||
"source": "gitea",
|
||||
"gitea": "gitea/tea"})
|
||||
assert len(ver) == 8
|
||||
assert ver.isdigit()
|
||||
assert ver.startswith('20')
|
||||
assert 'T' in ver
|
||||
|
||||
@pytest.mark.flaky(reruns=10)
|
||||
async def test_gitea_max_tag_with_include(get_version):
|
||||
|
|
Loading…
Add table
Reference in a new issue