Skip to content

Commit

Permalink
Move query limits tests to separate docker-compose file (#221)
Browse files Browse the repository at this point in the history
  • Loading branch information
adambollen authored Oct 5, 2023
1 parent 5d351ce commit 2732da7
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 26 deletions.
25 changes: 25 additions & 0 deletions concourse/scripts/docker-compose-fauna-limits.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
version: "3.5"

networks:
limit-net:
external: true
name: limit-net

services:
query-limits-tests:
image: node:20.2-alpine3.16
container_name: node-current-limits-test
networks:
- limit-net
volumes:
- "../../:/tmp/app"
working_dir: "/tmp/app"
environment:
FAUNA_ENDPOINT: ${FAUNA_ENDPOINT:-http://fauna-limits:8443}
QUERY_LIMITS_DB: ${QUERY_LIMITS_DB}
QUERY_LIMITS_COLL: ${QUERY_LIMITS_COLL}
command:
- /bin/sh
- -cxe
- |
yarn test:query-limits
25 changes: 1 addition & 24 deletions concourse/scripts/docker-compose-fauna.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,4 @@
version: "3.5"

networks:
limit-net:
external: true
name: limit-net
version: "3.3"

services:
faunadb:
Expand Down Expand Up @@ -49,21 +44,3 @@ services:
apk add --no-cache curl
./wait-for-it.sh http://faunadb:8443/ping
yarn test:integration
query-limits-tests:
image: node:20.2-alpine3.16
container_name: node-current-limits-test
networks:
- limit-net
volumes:
- "../../:/tmp/app"
working_dir: "/tmp/app"
environment:
FAUNA_ENDPOINT: ${FAUNA_ENDPOINT:-http://fauna-limits:8443}
QUERY_LIMITS_DB: ${QUERY_LIMITS_DB}
QUERY_LIMITS_COLL: ${QUERY_LIMITS_COLL}
command:
- /bin/sh
- -cxe
- |
yarn test:query-limits
4 changes: 2 additions & 2 deletions concourse/tasks/query-limits-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ run:
# setup Fauna container
docker-compose -f testtools-repo/fauna-driver-query-limits-tests/docker-compose.yml run setup
# run tests
docker-compose -f fauna-js-repository/concourse/scripts/docker-compose-fauna.yml run query-limits-tests
docker-compose -f fauna-js-repository/concourse/scripts/docker-compose-fauna-limits.yml run query-limits-tests
# stop and remove containers
docker-compose -f fauna-js-repository/concourse/scripts/docker-compose-fauna.yml down
docker-compose -f fauna-js-repository/concourse/scripts/docker-compose-fauna-limits.yml down
docker-compose -f testtools-repo/fauna-driver-query-limits-tests/docker-compose.yml down

0 comments on commit 2732da7

Please sign in to comment.