Skip to content

Commit

Permalink
Tried to remove errors on duplicate code in tests
Browse files Browse the repository at this point in the history
  • Loading branch information
francescalb committed Oct 17, 2023
1 parent 4d29686 commit da53897
Show file tree
Hide file tree
Showing 3 changed files with 33 additions and 1 deletion.
29 changes: 28 additions & 1 deletion .github/workflows/ci_tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ jobs:
update_docs_landing_page: true
package_dirs: tripper

pytest:
pytest-simple:
runs-on: ubuntu-latest

strategy:
Expand Down Expand Up @@ -85,3 +85,30 @@ jobs:
- name: Run doctest on tutorial
run: |
python -m doctest docs/tutorial.md
pytest: # Test for basic version, without extras installed
runs-on: ubuntu-latest

strategy:
fail-fast: false
matrix:
python-version: ["3.7", "3.8", "3.9", "3.10", "3.11"]

steps:
- name: Checkout tripper
uses: actions/checkout@v3

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}

- name: Install dependencies
run: |
sudo apt install graphviz
python -m pip install -U pip
pip install -U setuptools wheel flit
pip install -e .
- name: Test with pytest
run: pytest -vvv
2 changes: 2 additions & 0 deletions tests/test_collection.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@

# We have no dependencies on DLite, hence don't assume that it is installed.
# In case we have dlite, lets see if we can wrok with collections

# pylint disable=duplicate-code
try:
import dlite
except ImportError:
Expand Down
3 changes: 3 additions & 0 deletions tests/test_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@

# We have no dependencies on DLite, hence don't assume that it is installed.
# In case we have dlite, lets see if we can infer IRIs

# pylint: disable=duplicate-code

try:
import dlite
except ImportError:
Expand Down

0 comments on commit da53897

Please sign in to comment.