Skip to content

Commit

Permalink
Add back missing run_test.bat (#209)
Browse files Browse the repository at this point in the history
automerged PR by conda-forge/automerge-action
  • Loading branch information
github-actions[bot] authored May 25, 2023
2 parents 4206ae1 + e57749e commit 8911e6c
Show file tree
Hide file tree
Showing 3 changed files with 29 additions and 2 deletions.
2 changes: 1 addition & 1 deletion recipe/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ source:
sha256: {{ sha256 }}

build:
number: 0
number: 1
script: {{ PYTHON }} -m pip install . --no-deps --no-build-isolation -vv && {{ PYTHON }} -m conda init --install
# These are present when the new environment is created
# so we have to exempt them from the list of initial files
Expand Down
27 changes: 27 additions & 0 deletions recipe/run_test.bat
100644 → 100755
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
:: clear conda stuff from parent process
SET CONDA_SHLVL=
SET _CE_CONDA=
SET _CE_M=
SET _CONDA_EXE=

:: load shell interface
:: CALL is necessary because conda is a bat script,
:: running bat files within other bat files requires CALL or else
:: the outer script (our test script) exits when the inner completes
CALL %PREFIX%\condabin\conda_hook.bat

:: display conda details
CALL conda info --all

:: create, activate, and deactivate a conda environment
CALL conda create --yes --prefix ".\built-conda-test-env" "m2-patch"
IF NOT %ERRORLEVEL% == 0 EXIT /B 1

CALL conda activate ".\built-conda-test-env"
ECHO "CONDA_PREFIX=%CONDA_PREFIX%"

IF NOT "%CONDA_PREFIX%" == "%CD%\built-conda-test-env" EXIT /B 1
%CONDA_PREFIX%\Library\usr\bin\patch.exe --version
IF NOT %ERRORLEVEL% == 0 EXIT /B 1

CALL conda deactivate
2 changes: 1 addition & 1 deletion recipe/run_test.sh
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,4 @@ echo "CONDA_PREFIX=${CONDA_PREFIX}"
[[ "${CONDA_PREFIX}" == "${PWD}/built-conda-test-env" ]] || exit 1
${CONDA_PREFIX}/bin/patch --version || exit 1

conda deactivate
conda deactivate

0 comments on commit 8911e6c

Please sign in to comment.