Skip to content

adding missing s5cmd to python sci base #128

adding missing s5cmd to python sci base

adding missing s5cmd to python sci base #128

Workflow file for this run

name: Run Pytest
on:
push:
branches:
- 'main'
pull_request:
jobs:
build:
runs-on: ubuntu-latest
defaults:
run:
shell: bash -el {0}
strategy:
matrix:
python-version: [ "3.11" ]
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install python dependencies
run: |
python -m pip install --upgrade pip
pip install pytest pytest-cov pylint==2.17.5 python-dateutil==2.8.2 pint==0.21 importlib-metadata==6.7.0 jsonschema==4.19.0 pika==1.3.1 pyproj
- name: Set PYTHONPATH for pytest
run: |
echo "PYTHONPATH=python/idsse_common/idsse/common" >> $GITHUB_ENV
- name: Test with pytest
working-directory: python/idsse_common
run: |
pytest ./test --cov=./idsse/common --cov-report=term --junitxml=./test/pytest.xml | tee ./test/coverage.txt
- name: Pytest coverage comment
if: ${{ github.ref == 'refs/heads/main' }}
id: coverageComment
uses: MishaKav/pytest-coverage-comment@main
with:
hide-comment: true
pytest-coverage-path: python/idsse_common/test/coverage.txt
- name: Update Readme with Coverage Html
if: ${{ github.ref == 'refs/heads/main' }}
run: |
sed -i '/<!-- Pytest Coverage Comment:Begin -->/,/<!-- Pytest Coverage Comment:End -->/c\<!-- Pytest Coverage Comment:Begin -->\n\${{ steps.coverageComment.outputs.coverageHtml }}\n<!-- Pytest Coverage Comment:End -->' ./README.md
- name: Commit & Push changes to Readme
if: ${{ github.ref == 'refs/heads/main' }}
uses: actions-js/push@master
with:
message: Update coverage on Readme
github_token: ${{ secrets.GITHUB_TOKEN }}