diff options
author | Tyler Kennedy | 2022-12-01 11:53:45 -0500 |
---|---|---|
committer | GitHub | 2022-12-01 09:53:45 -0700 |
commit | ee9ac29cca27f3fad29ae12696ae715360db6cc7 (patch) | |
tree | a288a6a10eabf5c1394e7c6d4420314e85ca706e /.github/workflows | |
parent | 9fd70424bb54793613e93042bf157a03dc47a697 (diff) | |
download | takahe-ee9ac29cca27f3fad29ae12696ae715360db6cc7.tar.gz takahe-ee9ac29cca27f3fad29ae12696ae715360db6cc7.tar.bz2 takahe-ee9ac29cca27f3fad29ae12696ae715360db6cc7.zip |
Test support for sqlite. (#68)
Diffstat (limited to '.github/workflows')
-rw-r--r-- | .github/workflows/test.yml | 18 |
1 files changed, 16 insertions, 2 deletions
diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 5122986..9201f4c 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -10,10 +10,19 @@ on: jobs: test: + name: test py${{ matrix.python-version }} runs-on: ubuntu-latest strategy: matrix: python-version: ["3.10", "3.11"] + db: + - "postgres://postgres:postgres@localhost/postgres" + - "sqlite:///takahe.db" + include: + - db: "sqlite:///takahe.db" + search: false + - db: "postgres://postgres:postgres@localhost/postgres" + search: true services: postgres: image: postgres:15 @@ -22,7 +31,11 @@ jobs: POSTGRES_PASSWORD: postgres POSTGRES_DB: postgres ports: ["5432:5432"] - options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5 + options: >- + --health-cmd pg_isready + --health-interval 10s + --health-timeout 5s + --health-retries 5 steps: - uses: actions/checkout@v3 - name: Set up Python ${{ matrix.python-version }} @@ -35,7 +48,8 @@ jobs: python -m pip install -r requirements-dev.txt - name: Run pytest env: - TAKAHE_DATABASE_SERVER: "postgres://postgres:postgres@localhost:${{ job.services.postgres.ports[5432] }}/postgres" + TAKAHE_DATABASE_SERVER: ${{ matrix.db }} + TAKAHE_SEARCH: ${{ matrix.search }} TAKAHE_ENVIRONMENT: "test" TAKAHE_SECRET_KEY: "testing_secret" TAKAHE_MAIN_DOMAIN: "example.com" |