Skip to content

Commit

Permalink
set data directory in env
Browse files Browse the repository at this point in the history
  • Loading branch information
zacharyburnett committed Oct 18, 2022
1 parent 58981b8 commit b6801ea
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,9 @@ defaults:
run:
shell: bash -l {0}

env:
DATA_DIRECTORY: /home/runner/work/stenv/stenv/tests/data

jobs:
build:
name: build ${{ github.event.inputs.constraint }} Python ${{ matrix.python }} environment on ${{ matrix.os }}
Expand Down Expand Up @@ -98,10 +101,8 @@ jobs:
extras: [ test ]
commands: [
'curl -L https://stsci.box.com/shared/static/ntb71b3uusf1kzgf9bss0hzbreoja5gg.gz -o webbpsf-data.gz',
'tar -xvzf webbpsf-data.gz -C /home/runner/work/stenv/stenv/tests/data',
'tar -xvzf webbpsf-data.gz -C ${{ env.DATA_DIRECTORY }}',
]
env:
WEBBPSF_PATH: /home/runner/work/stenv/stenv/tests/data/webbpsf-data
data: true
steps:
- run: echo "CONSTRAINT=$(if [ -z ${{ github.event.inputs.constraint }} ]; then echo latest; else echo ${{ github.event.inputs.constraint }}; fi)" >> $GITHUB_ENV
Expand Down Expand Up @@ -156,7 +157,7 @@ jobs:
CRDS_SERVER_URL: ${{ matrix.env.CRDS_SERVER_URL }}
CRDS_PATH: ${{ env.CRDS_PATH }}
PYSYN_CDBS: ${{ env.PYSYN_CDBS }}
WEBBPSF_PATH: ${{ matrix.env.WEBBPSF_PATH }}
WEBBPSF_PATH: ${{ env.DATA_DIRECTORY }}/webbpsf-data
unit_tests_from_source:
name: run `${{ matrix.package }}` unit tests from source in ${{ github.event.inputs.constraint }} Python ${{ matrix.python }} environment on ${{ matrix.os }}
needs: [ build ]
Expand Down

0 comments on commit b6801ea

Please sign in to comment.