Skip to content

Commit

Permalink
Add test for GH #408 PackageRecord error
Browse files Browse the repository at this point in the history
  • Loading branch information
maresb committed Oct 19, 2023
1 parent f760313 commit 8961573
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 0 deletions.
6 changes: 6 additions & 0 deletions tests/test-git-package/environment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
channels:
- conda-forge
dependencies:
- git
platforms:
- osx-64
14 changes: 14 additions & 0 deletions tests/test_conda_lock.py
Original file line number Diff line number Diff line change
Expand Up @@ -1382,6 +1382,20 @@ def test_run_lock_relative_source_path(
assert [p.resolve() for p in src_files] == [environment.resolve()]


@pytest.fixture
def test_git_package_environment(tmp_path: Path):
return clone_test_dir("test-git-package", tmp_path).joinpath("environment.yml")


def test_git_gh_408(
monkeypatch: pytest.MonkeyPatch, test_git_package_environment: Path, conda_exe: str
):
monkeypatch.chdir(test_git_package_environment.parent)
if is_micromamba(conda_exe):
monkeypatch.setenv("CONDA_FLAGS", "-v")
run_lock([test_git_package_environment], conda_exe=conda_exe)


def test_run_lock_with_pip(
monkeypatch: "pytest.MonkeyPatch", pip_environment: Path, conda_exe: str
):
Expand Down

0 comments on commit 8961573

Please sign in to comment.