Skip to content

feat: Load CLR with Python.NET #61

feat: Load CLR with Python.NET

feat: Load CLR with Python.NET #61

# For more information see:
# https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python
name: Test code coverage
on:
push:
branches: ["main"]
pull_request_target:
branches: ["*"]
workflow_dispatch:
# Limit concurrent runs
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
permissions:
contents: read
jobs:
test:
name: indicators
runs-on: ubuntu-latest
env:
CODACY_PROJECT_TOKEN: ${{ secrets.CODACY_PROJECT_TOKEN }}
steps:
- name: Checkout PR
uses: actions/checkout@v4
with:
# Explicitly checkout PR code
ref: ${{ github.event.pull_request.head.sha }}
- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: 9.x
dotnet-quality: ga
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: 3.13
cache: "pip"
- name: Install dependencies
run: |
pip install -U --upgrade-strategy=only-if-needed pip
pip install -r requirements.txt
pip install -r requirements-test.txt
- name: Test indicators
run: |
coverage run -m --source=stock_indicators pytest
coverage xml
- name: Publish coverage to Codacy
uses: codacy/codacy-coverage-reporter-action@v1
with:
project-token: ${{ secrets.CODACY_PROJECT_TOKEN }}
coverage-reports: coverage.xml