Adding Workflow to run Integration Tests #25
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name : Integration Tests | |
on : | |
# allow manual triggering | |
workflow_dispatch: | |
# for debugging | |
push: | |
pull_request: | |
schedule: | |
# run Thursday 4:30 AM UTC | |
- cron: '30 4 * * 4' | |
jobs: | |
test: | |
runs-on: ubuntu-latest-4cores-16gb-20.04 | |
env: | |
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }} | |
container: | |
image: pecan/base:develop | |
steps: | |
- name: Checkout source code | |
uses: actions/checkout@v3 | |
- name: CDS API file setup | |
run: | | |
echo "url: https://cds.climate.copernicus.eu/api/v2" >> .cdsapirc | |
echo "key: ${{ secrets.ERA5_API_KEY }}" >> .cdsapirc | |
- name: Print Output to Console | |
run: | | |
cat .cdsapirc | |
- name: Set up Python | |
uses: actions/setup-python@v2 | |
- name: Download glibc | |
run: | | |
apt install libc6 | |
- name: Install dependencies | |
uses: BSFishy/pip-action@v1 | |
with: | |
packages: | | |
cdsapi | |
- name: Run tests | |
run: | | |
for FILE in modules/data.atmosphere/inst/integrationTests/*; do | |
Rscript $FILE; | |
done |