Skip to content

Commit

Permalink
Merge pull request getdokan#2222 from shashwatahalder01/litetests
Browse files Browse the repository at this point in the history
updated some e2e tests
  • Loading branch information
shashwatahalder01 authored Apr 2, 2024
2 parents e4ffb0d + df78ac1 commit 8d0ce23
Show file tree
Hide file tree
Showing 5 changed files with 250 additions and 236 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/e2e_api_tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ jobs:
if: success()
run: |
cd tests/pw
echo "DB_PORT=$(docker ps -f ancestor='mariadb' -f name='tests-mysql' --format='{{.Ports}}' | sed -E 's/.*:(.*)->.*/\1/')" >> $GITHUB_ENV
echo "DB_PORT=$(docker ps -f ancestor='mariadb:lts' -f name='tests-mysql' --format='{{.Ports}}' | sed -E 's/.*:(.*)->.*/\1/')" >> $GITHUB_ENV
# db port
- name: DB PORT
Expand Down Expand Up @@ -176,7 +176,7 @@ jobs:
# Run e2e tests
- name: 🧪 Running the e2e tests
id: e2e-test
if: success() || ( success() && (github.event_name == 'workflow_dispatch' && (github.event.inputs.testsuite == 'E2E' || github.event.inputs.testsuite == 'All')))
if: success() && (github.event_name != 'workflow_dispatch' || ( github.event_name == 'workflow_dispatch' && (github.event.inputs.testsuite == 'E2E' || github.event.inputs.testsuite == 'All')))
timeout-minutes: 40
run: |
cd tests/pw
Expand All @@ -185,7 +185,7 @@ jobs:
# Run API tests
- name: 🧪 Running the api tests
id: api-test
if: always() && steps.db-port.outcome == 'success' || ( always() && steps.db-port.outcome == 'success' && (github.event_name == 'workflow_dispatch' && (github.event.inputs.testsuite == 'API' || github.event.inputs.testsuite == 'All')))
if: steps.db-port.outcome == 'success' && ( github.event_name != 'workflow_dispatch' || ( github.event_name == 'workflow_dispatch' && (github.event.inputs.testsuite == 'API' || github.event.inputs.testsuite == 'All')))
timeout-minutes: 5
run: |
cd tests/pw
Expand Down Expand Up @@ -225,7 +225,7 @@ jobs:

# Backup Database
- name: Backup Database
if: steps.wp-env.outcome == 'success'
if: steps.db-port.outcome == 'success'
run: |
cd tests/pw
npm run wp-env run tests-cli wp db export wp-data/db.sql
Expand Down
Loading

0 comments on commit 8d0ce23

Please sign in to comment.