Skip to content

Commit

Permalink
Merge pull request #21 from alirashidAR/ci-tests
Browse files Browse the repository at this point in the history
Added GitHub Workflow for Automated Testing with pytest
  • Loading branch information
peterdudfield authored Dec 6, 2024
2 parents 9e5e379 + 7b8d6f1 commit 768da39
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 1 deletion.
19 changes: 19 additions & 0 deletions .github/workflows/pytest.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
name: Python package tests

on:
push:
pull_request:
types: [opened, synchronize, reopened]
schedule:
- cron: "0 12 * * 1"
pull_request_target:
types: [opened, synchronize, reopened, ready_for_review]
jobs:
call-run-python-tests:
uses: openclimatefix/.github/.github/workflows/python-test.yml@issue/pip-all
with:
# pytest-cov looks at this folder
pytest_cov_dir: "neso_solar_consumer"
os_list: '["ubuntu-latest"]'
python-version: "['3.11']"
pytest_numcpus: '1'
2 changes: 1 addition & 1 deletion tests/test_fetch_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
"""

import pytest
from fetch_data import fetch_data, fetch_data_using_sql
from neso_solar_consumer.fetch_data import fetch_data, fetch_data_using_sql


resource_id = "db6c038f-98af-4570-ab60-24d71ebd0ae5"
Expand Down

0 comments on commit 768da39

Please sign in to comment.