replaced tests #77
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-Package | |
on: | |
push | |
jobs: | |
build: | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: [macos-latest, ubuntu-latest, windows-latest] | |
python-version: ['3.9', '3.10'] | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v1 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Install first dependency | |
shell: bash | |
run: pip install pytest==7.1.2 | |
- name: Install second dependency | |
shell: bash | |
run: pip install pytest-cov==4.0.0 | |
- name: Install third dependency | |
shell: bash | |
run: pip install termcolor==2.1.0 | |
- name: Install forth dependency | |
shell: bash | |
run: pip install ujson==5.5.0 | |
- name: Print all libs | |
shell: bash | |
run: pip list | |
- name: Install the library | |
shell: bash | |
run: python setup.py install | |
- name: Run tests and show coverage on the command line | |
run: coverage run --source=polog --omit="*tests*" -m pytest --cache-clear && coverage report -m | |
- name: Upload reports to codecov | |
env: | |
CODECOV_TOKEN: ${{secrets.CODECOV_TOKEN}} | |
if: runner.os == 'Linux' | |
run: | | |
curl -Os https://uploader.codecov.io/latest/linux/codecov | |
find . -iregex "codecov.*" | |
chmod x codecov | |
./codecov -t ${CODECOV_TOKEN} |