Skip to content

Bump version to 0.4.6 #12

Bump version to 0.4.6

Bump version to 0.4.6 #12

Workflow file for this run

name: Run Pytest
on: [push, pull_request]
jobs:
test:
strategy:
matrix:
os: ["ubuntu-latest", "windows-latest", "macOS-latest"]
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12", "3.13"]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: Run unit tests
# Run unit tests against the mocked EIA API.
env:
EIA_TOKEN: "mock"
run: |
pytest tests/test_api.py
- name: Run integration tests
# Run integration tests against the EIA API. Not available on pull requests from forks.
env:
EIA_TOKEN: ${{ secrets.EIA_TOKEN }}
run: |
# Clear the mock data directory to trigger a real API call
python -c "import shutil; shutil.rmtree('./tests/data', ignore_errors=True);"
pytest tests/test_api.py
if: ${{ github.event_name == 'push' || github.event.pull_request.head.repo.fork == false }}