Skip to content

Commit

Permalink
merged with master
Browse files Browse the repository at this point in the history
  • Loading branch information
mauvais2 committed Oct 2, 2024
2 parents 969bc5f + d271984 commit ce1a426
Show file tree
Hide file tree
Showing 5 changed files with 44 additions and 29 deletions.
51 changes: 25 additions & 26 deletions .github/workflows/pytest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,15 +40,14 @@ jobs:
- name: pytest
run: |
# python3.9 -m pytest --capture=sys --capture=fd --cov=atomsci/ -vv atomsci/ddm/test/unit
python3.9 -m pytest --capture=sys --capture=fd --cov=atomsci/ -vv atomsci/modac/test/unit
cd atomsci/ddm/test/unit && python3.9 -m pytest -n 2 --capture=sys --capture=fd --cov=atomsci/ -vv
cd atomsci/ddm/test/unit && python3.9 -m pytest -n 2 --capture=sys --capture=fd --cov=atomsci -vv
env:
ENV: test

# - name: Upload coverage reports to Codecov
# uses: codecov/codecov-action@v3
# env:
# CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v4
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
pytest-integrative-1:
runs-on: ubuntu-latest
strategy:
Expand Down Expand Up @@ -86,15 +85,15 @@ jobs:
- name: pytest
run: |
# TODO: Run this test with pytest for paralell testing
# python3.9 -m pytest -n 2 --capture=sys --capture=fd --cov=atomsci/ -vv atomsci/ddm/test/integrative
# python3.9 -m pytest -n 2 --capture=sys --capture=fd --cov=atomsci -vv atomsci/ddm/test/integrative
cd atomsci/ddm/test/integrative && ./integrative_batch_chunk_tests 0
env:
ENV: test

# - name: Upload coverage reports to Codecov
# uses: codecov/codecov-action@v3
# env:
# CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v4
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
pytest-integrative-2:
runs-on: ubuntu-latest
strategy:
Expand Down Expand Up @@ -132,15 +131,15 @@ jobs:
- name: pytest
run: |
# TODO: Run this test with pytest for paralell testing
# python3.9 -m pytest -n 2 --capture=sys --capture=fd --cov=atomsci/ -vv atomsci/ddm/test/integrative
# python3.9 -m pytest -n 2 --capture=sys --capture=fd --cov=atomsci -vv atomsci/ddm/test/integrative
cd atomsci/ddm/test/integrative && ./integrative_batch_chunk_tests 1
env:
ENV: test

# - name: Upload coverage reports to Codecov
# uses: codecov/codecov-action@v3
# env:
# CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v4
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
pytest-integrative-3:
runs-on: ubuntu-latest
strategy:
Expand Down Expand Up @@ -178,15 +177,15 @@ jobs:
- name: pytest
run: |
# TODO: Run this test with pytest for paralell testing
# python3.9 -m pytest -n 2 --capture=sys --capture=fd --cov=atomsci/ -vv atomsci/ddm/test/integrative
# python3.9 -m pytest -n 2 --capture=sys --capture=fd --cov=atomsci -vv atomsci/ddm/test/integrative
cd atomsci/ddm/test/integrative && ./integrative_batch_chunk_tests 2
env:
ENV: test

# - name: Upload coverage reports to Codecov
# uses: codecov/codecov-action@v3
# env:
# CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v4
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
pytest-integrative-4:
runs-on: ubuntu-latest
strategy:
Expand Down Expand Up @@ -224,12 +223,12 @@ jobs:
- name: pytest
run: |
# TODO: Run this test with pytest for paralell testing
# python3.9 -m pytest -n 2 --capture=sys --capture=fd --cov=atomsci/ -vv atomsci/ddm/test/integrative
# python3.9 -m pytest -n 2 --capture=sys --capture=fd --cov=atomsci -vv atomsci/ddm/test/integrative
cd atomsci/ddm/test/integrative && ./integrative_batch_chunk_tests 3
env:
ENV: test

# - name: Upload coverage reports to Codecov
# uses: codecov/codecov-action@v3
# env:
# CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v4
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ pytest-integrative:
pytest-unit:
@echo "Running unit tests"
docker run -v $(shell pwd)/$(WORK_DIR):/$(WORK_DIR) $(IMAGE_REPO):$(TAG) \
/bin/bash -l -c "cd atomsci/ddm/test/unit && python3.9 -m pytest --capture=sys --capture=fd --cov=atomsci/ -vv"
/bin/bash -l -c "cd atomsci/ddm/test/unit && python3.9 -m pytest --capture=sys --capture=fd --cov=atomsci -vv"

# Run ruff linter
ruff:
Expand Down
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
[![Develop test](https://github.com/ATOMScience-org/AMPL/actions/workflows/pytest.yml/badge.svg)](https://github.com/ATOMScience-org/AMPL/actions/workflows/pytest.yml) [![Linter](https://github.com/ATOMScience-org/AMPL/actions/workflows/lint.yml/badge.svg)](https://github.com/ATOMScience-org/AMPL/actions/workflows/lint.yml) [![Documentation Status](https://readthedocs.org/projects/ampl/badge/?version=stable)](https://ampl.readthedocs.io/en/latest/?badge=stable)
![GitHub Release](https://img.shields.io/github/v/release/ATOMScience-org/AMPL) [![License](http://img.shields.io/:license-mit-blue.svg)](https://github.com/ATOMScience-org/AMPL/blob/master/LICENSE) [![LinkedIn](https://img.shields.io/badge/linkedin-%230077B5.svg?logo=linkedin&logoColor=white)](https://www.linkedin.com/company/atomscience)
[![codecov](https://codecov.io/gh/ATOMScience-org/AMPL/graph/badge.svg)](https://codecov.io/gh/ATOMScience-org/AMPL)

![GitHub Release](https://img.shields.io/github/v/release/ATOMScience-org/AMPL) [![License](http://img.shields.io/:license-mit-blue.svg)](https://github.com/ATOMScience-org/AMPL/blob/master/LICENSE) [![LinkedIn](https://img.shields.io/badge/linkedin-%230077B5.svg?logo=linkedin&logoColor=white)](https://www.linkedin.com/company/atomscience)

| [Install](#install) | [Docker](#install-with-docker) | [Tutorials](#ampl-tutorials) | [Features](#ampl-features) | [Pipeline parameters](atomsci/ddm/docs/PARAMETERS.md) | [Docs](https://ampl.readthedocs.io/en/latest/) |

Expand Down
2 changes: 1 addition & 1 deletion atomsci/ddm/test/integrative/integrative_batch_chunk_tests
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ for folder in "${folders[@]}"; do
if [[ -f "$file" && "$folder" != "__pycache__/" ]]; then
cd "$folder"
echo "Testing $folder"
pytest --capture=sys --capture=fd --cov=atomsci/ -vv
pytest --capture=sys --capture=fd --cov=atomsci -vv
cd ..
else
echo "Skipping folder: $folder. Not a test directory."
Expand Down
14 changes: 14 additions & 0 deletions codecov.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
comment: # this is a top-level key
layout: " diff, flags, files"
behavior: default
require_changes: false # if true: only post the comment if coverage changes
require_base: false # [true :: must have a base report to post]
require_head: true # [true :: must have a head report to post]

ignore:
- "venv"
- ".venv"
- "pip"

github_checks:
annotations: false

0 comments on commit ce1a426

Please sign in to comment.