|
3 | 3 | from setuptools_scm.version import meta, simplified_semver_version, tags_to_versions
|
4 | 4 |
|
5 | 5 |
|
| 6 | +c = Configuration() |
| 7 | + |
| 8 | + |
6 | 9 | @pytest.mark.parametrize(
|
7 | 10 | "version, expected_next",
|
8 | 11 | [
|
9 |
| - pytest.param(meta("1.0.0"), "1.0.0", id="exact"), |
10 |
| - pytest.param(meta("1.0"), "1.0.0", id="short_tag"), |
| 12 | + pytest.param(meta("1.0.0", config=c), "1.0.0", id="exact"), |
| 13 | + pytest.param(meta("1.0", config=c), "1.0.0", id="short_tag"), |
11 | 14 | pytest.param(
|
12 |
| - meta("1.0.0", distance=2, branch="default"), |
| 15 | + meta("1.0.0", distance=2, branch="default", config=c), |
13 | 16 | "1.0.1.dev2",
|
14 | 17 | id="normal_branch",
|
15 | 18 | ),
|
16 | 19 | pytest.param(
|
17 |
| - meta("1.0", distance=2, branch="default"), |
| 20 | + meta("1.0", distance=2, branch="default", config=c), |
18 | 21 | "1.0.1.dev2",
|
19 | 22 | id="normal_branch_short_tag",
|
20 | 23 | ),
|
21 | 24 | pytest.param(
|
22 |
| - meta("1.0.0", distance=2, branch="feature"), |
| 25 | + meta("1.0.0", distance=2, branch="feature", config=c), |
23 | 26 | "1.1.0.dev2",
|
24 | 27 | id="feature_branch",
|
25 | 28 | ),
|
26 | 29 | pytest.param(
|
27 |
| - meta("1.0", distance=2, branch="feature"), |
| 30 | + meta("1.0", distance=2, branch="feature", config=c), |
28 | 31 | "1.1.0.dev2",
|
29 | 32 | id="feature_branch_short_tag",
|
30 | 33 | ),
|
31 | 34 | pytest.param(
|
32 |
| - meta("1.0.0", distance=2, branch="features/test"), |
| 35 | + meta("1.0.0", distance=2, branch="features/test", config=c), |
33 | 36 | "1.1.0.dev2",
|
34 | 37 | id="feature_in_branch",
|
35 | 38 | ),
|
|
0 commit comments