Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
kelanik8 committed Nov 22, 2023
1 parent e1bad5d commit af9902a
Showing 1 changed file with 33 additions and 37 deletions.
70 changes: 33 additions & 37 deletions .github/workflows/test-e2e.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,8 @@ jobs:
name: "server and client test"
strategy:
matrix:
client: [ admin, compose, discovery, privacy, reporter, one, workflow ]
client: [ admin, compose, reporter, workflow ]
test: [ admin, compose, topbar, reporter, workflow, server]
runs-on: ubuntu-20.04
steps:
- name: Setup tmate session
Expand Down Expand Up @@ -120,57 +121,52 @@ jobs:
- name: Wait for postgres healthcheck
run: timeout 180s sh -c 'until docker ps | grep corteza_postgres_1 | grep -q healthy; do echo "Waiting for container to be healthy..."; sleep 1; done'

- name: Wait for admin healthcheck
run: timeout 180s sh -c 'until docker ps | grep admin | grep -q healthy; do echo "Waiting for container to be healthy..."; sleep 1; done'
- name: Wait for "${{ matrix.client }}" healthcheck
env:
CLIENT_NAME: ${{ matrix.client }}
run: timeout 180s sh -c 'until docker ps | grep ${CLIENT_NAME} | grep -q healthy; do echo "Waiting for container to be healthy..."; sleep 1; done'

- name: Wait for backend healthcheck
run: timeout 180s sh -c 'until docker ps | grep corteza_backend_1 | grep -q healthy; do echo "Waiting for container to be healthy..."; sleep 1; done'

- name: Run Admin CY tests
working-directory: corteza-e2e-cypress
if: matrix.client == 'admin'
run: |
docker ps
yarn install
docker-compose run \
--name admin-cy \
--use-aliases \
--entrypoint='cypress run
--spec cypress/integration/basic-functionalities/server/Create_user.spec.js
--browser chrome' \
cypress
docker-compose run \
--name admin-cy \
--use-aliases \
--entrypoint='cypress run
--spec cypress/integration/basic-functionalities/admin/index.js
--browser chrome' \
cypress
- name: Run Compose CY tests
- name: Run CY tests for "${{ matrix.test }}"
env:
TEST_NAME: ${{ matrix.test }}
working-directory: corteza-e2e-cypress
if: matrix.client == 'compose'
run: |
docker ps
yarn install
docker-compose run \
--name cypress \
--name ${TEST_NAME}-cy \
--use-aliases \
--entrypoint='cypress run
--spec cypress/integration/basic-functionalities/server/Create_user.spec.js
--spec cypress/integration/basic-functionalities/${TEST_NAME}/index.js
--browser chrome' \
cypress
docker-compose run \
--name cypress \
--use-aliases \
--entrypoint='cypress run
--spec cypress/integration/basic-functionalities/compose/index.js
--browser chrome' \
cypress
# - name: Run Compose CY tests
# working-directory: corteza-e2e-cypress
# if: matrix.client == 'compose'
# run: |
# docker ps
# yarn install

# docker-compose run \
# --name cypress \
# --use-aliases \
# --entrypoint='cypress run
# --spec cypress/integration/basic-functionalities/server/Create_user.spec.js
# --browser chrome' \
# cypress

# docker-compose run \
# --name cypress \
# --use-aliases \
# --entrypoint='cypress run
# --spec cypress/integration/basic-functionalities/compose/index.js
# --browser chrome' \
# cypress

# client-web-test:
# name: "Web client test (${{ matrix.app }})"
Expand Down

0 comments on commit af9902a

Please sign in to comment.