-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
BUG fix bug in getting run exports, refactor a bit more
- Loading branch information
Showing
4 changed files
with
73 additions
and
45 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
import pytest | ||
|
||
from conda_forge_feedstock_check_solvable.utils import ( | ||
convert_spec_to_conda_build, | ||
get_run_export, | ||
) | ||
|
||
@pytest.mark.parametrize( | ||
"inreq,outreq", | ||
[ | ||
("blah 1.1*", "blah 1.1.*"), | ||
("blah * *_osx", "blah * *_osx"), | ||
("blah 1.1", "blah 1.1.*"), | ||
("blah =1.1", "blah 1.1.*"), | ||
("blah * *_osx", "blah * *_osx"), | ||
("blah 1.2 *_osx", "blah 1.2.* *_osx"), | ||
("blah >=1.1", "blah >=1.1"), | ||
("blah >=1.1|5|>=5,<10|19.0", "blah >=1.1|5.*|>=5,<10|19.0.*"), | ||
("blah >=1.1|5| >=5 , <10 |19.0", "blah >=1.1|5.*|>=5,<10|19.0.*"), | ||
], | ||
) | ||
def test_convert_spec_to_conda_build(inreq, outreq): | ||
assert convert_spec_to_conda_build(inreq) == outreq | ||
|
||
|
||
@pytest.mark.parametrize( | ||
"full_channel_url,filename,expected", | ||
[ | ||
("https://conda.anaconda.org/conda-forge/osx-arm64", "openjdk-22.0.1-hbeb2e11_0.conda", None), | ||
], | ||
) | ||
def test_utils_get_run_export(full_channel_url, filename, expected): | ||
get_run_export(full_channel_url, filename) == expected |