Skip to content

Commit

Permalink
Run conda tests inside base environment, so that conda build tools ar…
Browse files Browse the repository at this point in the history
…e available. Also pip install pshmem in python-3.12 case since sysv_ipc package not available yet.
  • Loading branch information
tskisner committed Feb 1, 2024
1 parent 668bf99 commit 81aa538
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ jobs:
source ~/conda/etc/profile.d/conda.sh
conda activate base
conda update -n base --yes conda
conda install -n base --yes python==${{ matrix.python }}
- name: Check Conda Config
run: |
Expand All @@ -83,22 +84,24 @@ jobs:
source ~/conda/etc/profile.d/conda.sh
conda activate base
if [ "${{ matrix.python }}" = "3.12" ]; then
./platforms/conda_dev_setup.sh toast ${{ matrix.python }} no
# For python-3.12 we workaround multiple issues...
./platforms/conda_dev_setup.sh base ${{ matrix.python }} no
python -m pip install --upgrade --force-reinstall pshmem
else
./platforms/conda_dev_setup.sh toast ${{ matrix.python }} yes
./platforms/conda_dev_setup.sh base ${{ matrix.python }} yes
fi
- name: Install
run: |
source ~/conda/etc/profile.d/conda.sh
conda activate toast
conda activate base
export TOAST_BUILD_DISABLE_OPENMP=${{ matrix.ompdisable }}
./platforms/conda.sh
- name: Run Serial Tests
run: |
source ~/conda/etc/profile.d/conda.sh
conda activate toast
conda activate base
export OMP_NUM_THREADS=2
export MPI_DISABLE=1
python3 -c 'import toast.tests; toast.tests.run()'
Expand All @@ -108,7 +111,7 @@ jobs:
- name: Run MPI Tests
run: |
source ~/conda/etc/profile.d/conda.sh
conda activate toast
conda activate base
export OMP_NUM_THREADS=1
mpirun -np 2 python -c 'import toast.tests; toast.tests.run()'
unset OMP_NUM_THREADS
Expand Down

0 comments on commit 81aa538

Please sign in to comment.