Skip to content

Commit 6c6eebe

Browse files
committed
Refactor CI workflow to initialize micromamba shell and remove redundant activation commands
1 parent 7b73d5f commit 6c6eebe

File tree

1 file changed

+5
-8
lines changed

1 file changed

+5
-8
lines changed

.github/workflows/run_tests.yml

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -22,28 +22,25 @@ jobs:
2222
environment-file: environment.yml
2323
cache-downloads: true
2424

25+
- name: Initialize micromamba shell
26+
run: |
27+
eval "$(micromamba shell hook --shell bash)"
28+
micromamba activate P_microSALT
29+
2530
- name: Activate Conda environment and install microSALT
2631
run: |
27-
source ~/.bashrc
28-
micromamba activate P_microSALT
2932
python -m pip install -r requirements.txt -r requirements-dev.txt
3033
python -m pip install -U .
3134
3235
- name: Lint with flake8
3336
run: |
34-
source ~/.bashrc
35-
micromamba activate P_microSALT
3637
flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
3738
flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
3839
3940
- name: Test with pytest
4041
run: |
41-
source ~/.bashrc
42-
micromamba activate P_microSALT
4342
pytest --cov=microSALT tests
4443
4544
- name: Run Coveralls
4645
run: |
47-
source ~/.bashrc
48-
micromamba activate P_microSALT
4946
coveralls

0 commit comments

Comments
 (0)