Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add tests to GitHub #32

Merged
merged 7 commits into from
Mar 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/publish-to-pypi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: Publish Python 🐍 distribution 📦 to PyPI

on:
push:
branches: [master, build/*]
branches: [main, build/*]

jobs:
build:
Expand All @@ -20,7 +20,7 @@ jobs:
run: |
sed -i "/__version__/d" twinn_ml_interface/_version.py
sed -i "s/__dev_version__/__version__/g" twinn_ml_interface/_version.py
if: github.ref != 'refs/heads/master'
if: github.ref != 'refs/heads/main'

- name: Install pypa/build
run: >-
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/publish-to-test-pypi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: Publish Python 🐍 distribution 📦 to TestPyPI

on:
push:
branches: [master, build/*]
branches: [main, build/*]

jobs:
build:
Expand All @@ -20,7 +20,7 @@ jobs:
run: |
sed -i "/__version__/d" twinn_ml_interface/_version.py
sed -i "s/__dev_version__/__version__/g" twinn_ml_interface/_version.py
if: github.ref != 'refs/heads/master'
if: github.ref != 'refs/heads/main'

- name: Install pypa/build
run: >-
Expand Down
30 changes: 7 additions & 23 deletions .github/workflows/validate_pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,26 +32,10 @@ jobs:
- name: 'Run all pre-commit linters'
run: |
pre-commit run --all-files --show-diff-on-failure

# testing: # TODO: Activate when Custom Protocol is public

# runs-on: ubuntu-latest
# strategy:
# fail-fast: false
# matrix:
# python-version: ["3.10"]

# steps:
# - uses: actions/checkout@v3
# - name: Set up Python ${{ matrix.python-version }}
# uses: actions/setup-python@v3
# with:
# python-version: ${{ matrix.python-version }}
# - name: Install pre-commit
# run: |
# python -m pip install --upgrade pip
# python -m pip install pytest
# pip install .
# - name: Test with pytest
# run: |
# pytest tests/
- name: Prepare for testing
run: |
python -m pip install pytest
pip install .
- name: Test with pytest
run: |
pytest tests/
Loading