-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
5 changed files
with
434 additions
and
107 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
name: CI | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
pull_request: | ||
|
||
jobs: | ||
test: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
python-version: [3.7, 3.8] | ||
|
||
env: | ||
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} | ||
|
||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v2 | ||
|
||
- name: Set up Python | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
|
||
- name: Install dependencies | ||
run: | | ||
python -m pip install --upgrade pip | ||
pip install tox-travis flake8 tox pytest matplotlib==3.3.4 pytest-cov codecov | ||
pip install dash-bootstrap-components dash[testing] webdriver_manager selenium | ||
pip install --upgrade setuptools importlib-metadata | ||
pip install -e . | ||
- name: Install Chrome | ||
run: | | ||
sudo apt-get update | ||
sudo apt-get install -y google-chrome-stable libnss3 | ||
- name: Install Chromedriver | ||
run: | | ||
wget http://chromedriver.storage.googleapis.com/106.0.5249.61/chromedriver_linux64.zip | ||
unzip chromedriver_linux64.zip | ||
sudo mv chromedriver /usr/local/bin/chromedriver | ||
sudo chmod +x /usr/local/bin/chromedriver | ||
- name: Run tests with coverage | ||
env: | ||
DISPLAY: :99.0 | ||
run: | | ||
Xvfb :99 & sleep 3 | ||
pytest --cov=vital_sqi tests | ||
- name: Upload coverage to Codecov | ||
uses: codecov/codecov-action@v2 | ||
with: | ||
token: ${{ secrets.CODECOV_TOKEN }} | ||
fail_ci_if_error: true | ||
flags: unittests |
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
Oops, something went wrong.