add test, release v0.1.1 #2
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
name: test sacrecomet | |
on: | |
push: | |
branches: [ "main" ] | |
pull_request: | |
branches: [ "main" ] | |
permissions: | |
contents: read | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Python 3.11.5 | |
uses: actions/setup-python@v5 | |
with: | |
python-version: '3.11.5' | |
cache: 'pip' # caching pip dependencies | |
- name: Install dependencies | |
run: | | |
pip install --upgrade pip | |
pip install flake8 pytest | |
# install specific version for testing | |
pip install unbabel_comet==2.2.4 | |
pip install -e python-tool | |
- name: Lint with flake8 | |
run: | | |
# stop the build if there are Python syntax errors or undefined names | |
flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics | |
- name: Test python-tool/test.py with pytest | |
run: | | |
pytest -v python-tool/test.py |