Skip to content

ci: bump actions/checkout from 2 to 4 #54

ci: bump actions/checkout from 2 to 4

ci: bump actions/checkout from 2 to 4 #54

Workflow file for this run

name: Build and Test (Flit)
on:
push:
branches:
- '**'
pull_request:
branches:
- '**'
jobs:
build-and-test-flit:
runs-on: ubuntu-latest
steps:
# Step 1: Check out the repository
- name: Check out repository
uses: actions/checkout@v4
# Step 2: Set up Python
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.11'
# Step 3: Install Flit, pytest, pytest-cov, and Coverage
- name: Install Flit, pytest, pytest-cov, and Coverage
run: |
pip install flit pytest pytest-cov coverage[toml]
# Step 4: Install dependencies (including dev dependencies)
- name: Install package (dev extras)
env:
FLIT_ROOT_INSTALL: "1"
run: |
flit install --deps develop --extras dev
# Step 5: Run tests with coverage
- name: Run tests with coverage
run: |
pytest --cov=gds_fdtd --cov-branch --cov-report=xml
# Step 6: Upload coverage reports to Codecov
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v5
with:
token: ${{ secrets.CODECOV_TOKEN }}
slug: SiEPIC/gds_fdtd
files: coverage.xml
flags: unittests