Skip to content

Commit

Permalink
simplify venv preparation
Browse files Browse the repository at this point in the history
  • Loading branch information
DanielYang59 committed Dec 4, 2024
1 parent ae0d664 commit b98d76c
Showing 1 changed file with 16 additions and 14 deletions.
30 changes: 16 additions & 14 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
test:
defaults:
run:
shell: bash -l {0} # enables conda/mamba env activation by reading bash profile
shell: bash -l {0} # enables conda/mamba env activation by reading bash profile
strategy:
fail-fast: false
matrix:
Expand All @@ -33,24 +33,26 @@ jobs:

- name: Set up micromamba
uses: mamba-org/setup-micromamba@main

- name: Create mamba environment
run: |
micromamba create -n venv python=${{ matrix.python-version }} --yes
micromamba install -n venv -c conda-forge enumlib packmol bader openbabel openff-toolkit --yes
with:
environment-name: matgenb
condarc: |
channels:
- conda-forge
create-args: >-
python=${{ matrix.python-version }}
enumlib
packmol
bader
openbabel
openff-toolkit
- name: Install uv
uses: astral-sh/setup-uv@v4
with:
version: "latest"

- name: Install dependencies
- name: Install dependencies and run pytest
run: |
micromamba activate venv
micromamba activate matgenb
uv pip install --upgrade -r requirements-ci.txt
- name: pytest
run: |
micromamba activate venv
cd notebooks
pytest --ignore-glob=*notest.ipynb --nbmake .
pytest --ignore-glob=*notest.ipynb --nbmake notebooks/

0 comments on commit b98d76c

Please # to comment.