Skip to content

Merge pull request #4 from Zhaopudark/dev #78

Merge pull request #4 from Zhaopudark/dev

Merge pull request #4 from Zhaopudark/dev #78

Workflow file for this run

name: Test
on:
push:
branches:
- main
- dev
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: conda-incubator/setup-miniconda@v3
with:
auto-update-conda: true
python-version: 3.12
activate-environment: pandoc_filter_dev
environment-file: ./scripts/etc/environment.yml
- name: distribution package test
env:
OSS_ENDPOINT_NAME: ${{ secrets.OSS_ENDPOINT_NAME }}
OSS_BUCKET_NAME: ${{ secrets.OSS_BUCKET_NAME }}
OSS_ACCESS_KEY_ID: ${{ secrets.OSS_ACCESS_KEY_ID }}
OSS_ACCESS_KEY_SECRET: ${{ secrets.OSS_ACCESS_KEY_SECRET }}
shell: pwsh
run: |
python -m build
pip install (Get-Item "./dist/*.whl").FullName
$package_path = "$(((pip show pandoc-filter) -match 'Location:')[0] -replace 'Location:\s+')/pandoc_filter"
$Env:PYTHONIOENCODING='utf-8'
pytest (Get-Item "./tests").FullName --log-level=INFO --cov=$package_path --cov-report=xml
- uses: codecov/codecov-action@v4
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}