fix failing snowflake test #51
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
on: | |
push: | |
branches: [main, master, test] | |
pull_request: | |
branches: [main, master] | |
name: postgres-test | |
jobs: | |
Postgres-test: | |
# if: github.repository == 'darwin-eu/CDMConnector' | |
runs-on: ubuntu-latest | |
container: | |
image: executionengine.azurecr.io/darwin-base:v0.2 | |
env: | |
CDM5_POSTGRESQL_USER: ${{ secrets.CDM5_POSTGRESQL_USER }} | |
CDM5_POSTGRESQL_PORT: ${{ secrets.CDM5_POSTGRESQL_PORT }} | |
CDM5_POSTGRESQL_PASSWORD: ${{ secrets.CDM5_POSTGRESQL_PASSWORD }} | |
CDM5_POSTGRESQL_SERVER: ${{ secrets.CDM5_POSTGRESQL_SERVER }} | |
CDM5_POSTGRESQL_HOST: ${{ secrets.CDM5_POSTGRESQL_HOST }} | |
CDM5_POSTGRESQL_DBNAME: ${{ secrets.CDM5_POSTGRESQL_DBNAME }} | |
CDM5_POSTGRESQL_CDM_SCHEMA: ${{ secrets.CDM5_POSTGRESQL_CDM_SCHEMA }} | |
CDM5_POSTGRESQL_OHDSI_SCHEMA: ${{ secrets.CDM5_POSTGRESQL_OHDSI_SCHEMA }} | |
CDM5_POSTGRESQL_SCRATCH_SCHEMA: ${{ secrets.CDM5_POSTGRESQL_SCRATCH_SCHEMA }} | |
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }} | |
name: Postgres test (RPostgres driver) | |
strategy: | |
fail-fast: true | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Run a simple shell command | |
run: ls | |
- name: Run one R command | |
run: R -e "getwd()" | |
- name: Run several R commands | |
run: | | |
print(getwd()) | |
print(list.files()) | |
shell: Rscript {0} | |
- name: Run tests on postgres with RPostgres driver | |
run: R -e 'withr::with_envvar(new = c("CI_TEST_DB" = "postgres"), testthat::test_local())' | |