forked from guillermo-carrasco/TACA
-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #34 from SciLifeLab/master
Version sync
- Loading branch information
Showing
108 changed files
with
151,231 additions
and
1,081 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
name: Test code | ||
on: [push, pull_request] | ||
|
||
jobs: | ||
pytest: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout repo | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
- name: Set up Python | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: "3.10" | ||
- name: Install dependencies | ||
run: | | ||
python -m pip install --upgrade pip | ||
pip install -r requirements.txt | ||
pip install -r requirements-dev.txt | ||
- name: Install TACA | ||
run: pip install -e . | ||
- name: pytest | ||
# Options are configured in pyproject.toml | ||
run: pytest | ||
- name: CodeCov | ||
run: | | ||
# Replace `linux` below with the appropriate OS | ||
# Options are `alpine`, `linux`, `macos`, `windows` | ||
curl -Os https://uploader.codecov.io/latest/linux/codecov | ||
chmod +x codecov | ||
./codecov -t ${{ secrets.CODECOV_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -13,3 +13,4 @@ __pycache__ | |
.vscode | ||
.ruff_cache | ||
.mypy_cache | ||
node_modules |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,27 +1,45 @@ | ||
title = "taca" | ||
|
||
# === LINTING ================================================================ | ||
|
||
[tool.ruff] | ||
exclude = ["tests_old/**"] | ||
|
||
[tool.ruff.lint] | ||
select =[ | ||
select = [ | ||
# Ruff default rules | ||
# ------------------------------ | ||
"E4", # pycodestyle Imports | ||
"E7", # pycodestyle Statements | ||
"E9", # pycodestyle Runtime | ||
"F", # Pyflakes | ||
"E4", # pycodestyle Imports | ||
"E7", # pycodestyle Statements | ||
"E9", # pycodestyle Runtime | ||
"F", # Pyflakes | ||
|
||
# Additional Comment | ||
# ------------------------------------------------------ | ||
"I", # isort Best-practice sorting of imports | ||
"UP", # pyupgrade Make sure syntax is up-to-date | ||
"I", # isort Best-practice sorting of imports | ||
"UP", # pyupgrade Make sure syntax is up-to-date | ||
] | ||
ignore = [ | ||
"E402", # Module level import not at top of file | ||
"E722", # Do not use bare 'except' | ||
"E741", # Ambiguous variable name | ||
] | ||
|
||
|
||
[tool.mypy] | ||
ignore_missing_imports = true | ||
follow_imports = 'skip' | ||
|
||
# === Testing ================================================================ | ||
|
||
[tool.pytest.ini_options] | ||
# Omit deprecation warnings from 3rd party packages | ||
filterwarnings = [ | ||
'ignore::DeprecationWarning:couchdb.*', | ||
'ignore::DeprecationWarning:pkg_resources.*', | ||
] | ||
addopts = "--cov=./taca --cov-report term-missing -vv --cache-clear tests/" | ||
|
||
[tool.coverage.run] | ||
# The comment "# pragma: no cover" can be used to exclude a line from coverage | ||
source = ["taca"] | ||
omit = ["**/__init__.py"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,6 +5,7 @@ mock | |
sphinx | ||
sphinx-rtd-theme | ||
pytest | ||
pytest-cov | ||
ipython | ||
ipdb | ||
ruff | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,3 @@ | ||
""" Main TACA module | ||
""" | ||
"""Main TACA module""" | ||
|
||
__version__ = "1.0.0" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.