2017-02-28 07:24:53 +00:00
|
|
|
# MIT licensed
|
|
|
|
# Copyright (c) 2013-2017 lilydjwg <lilydjwg@gmail.com>, et al.
|
2015-11-05 04:12:03 +00:00
|
|
|
|
2017-07-04 09:04:29 +00:00
|
|
|
import pytest
|
2019-10-15 09:27:34 +00:00
|
|
|
pytestmark = [pytest.mark.asyncio, pytest.mark.needs_net]
|
2015-11-05 04:12:03 +00:00
|
|
|
|
2017-07-04 09:04:29 +00:00
|
|
|
async def test_bitbucket(get_version):
|
|
|
|
assert await get_version("example", {"bitbucket": "prawee/git-tag"}) == "20150303"
|
2015-11-05 04:12:03 +00:00
|
|
|
|
2017-07-04 09:04:29 +00:00
|
|
|
async def test_bitbucket_max_tag(get_version):
|
|
|
|
assert await get_version("example", {"bitbucket": "prawee/git-tag", "use_max_tag": 1}) == "1.7.0"
|
2015-12-23 13:02:06 +00:00
|
|
|
|
2017-07-04 09:04:29 +00:00
|
|
|
async def test_bitbucket_max_tag_with_ignored_tags(get_version):
|
|
|
|
assert await get_version("example", {"bitbucket": "prawee/git-tag", "use_max_tag": 1, "ignored_tags": "1.6.0 1.7.0"}) == "v1.5"
|