-
Notifications
You must be signed in to change notification settings - Fork 98
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' of https://github.com/cdpierse/transformers-int…
- Loading branch information
Showing
14 changed files
with
849 additions
and
623 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
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,45 @@ | ||
--- | ||
name: Unit Tests | ||
on: push | ||
jobs: | ||
tests: | ||
runs-on: ubuntu-20.04 | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v1 | ||
|
||
- name: Set up Python 3.7.13 | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: 3.7.13 | ||
|
||
- name: Install poetry | ||
run: | | ||
which python | ||
which pip | ||
pip install poetry | ||
- name: Install Python dependencies | ||
if: steps.cache-poetry.outputs.cache-hit != 'true' | ||
run: | | ||
poetry install | ||
- name: Run Unit tests | ||
|
||
run: | | ||
export PATH="$HOME/.pyenv/bin:$PATH" | ||
export PYTHONPATH="." | ||
poetry run pytest -s --cov=transformers_interpret/ --cov-report term-missing \ | ||
test | ||
- name: Report coverage | ||
run: | | ||
export PATH="$HOME/.pyenv/bin:$PATH" | ||
poetry run coverage report --fail-under=50 | ||
poetry run coverage html -d unit_htmlcov | ||
- uses: actions/upload-artifact@v2 | ||
with: | ||
name: ti-unit-coverage | ||
path: ti-unit-htmlcov/ |
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
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.