-
Notifications
You must be signed in to change notification settings - Fork 412
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
test: e2e concurrency + split e2e tests (#2761)
Co-authored-by: novakzaballa <zaballa.novak@gmail.com> Co-authored-by: Novak Zaballa <41410593+novakzaballa@users.noreply.github.com>
- Loading branch information
1 parent
da52a96
commit b1d3323
Showing
32 changed files
with
3,377 additions
and
3,183 deletions.
There are no files selected for viewing
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
name: Run E2E tests in local environment | ||
description: Run the E2E tests against local environment | ||
|
||
inputs: | ||
slack_token: | ||
description: The slack authentication token. | ||
required: true | ||
tests: | ||
description: The space separated list of E2E tests to be executed. | ||
required: false | ||
default: '' | ||
concurrency: | ||
description: The concurrent number of browsers to be used on testing. | ||
required: false | ||
default: 3 | ||
|
||
runs: | ||
using: composite | ||
|
||
steps: | ||
- name: Run Local API | ||
id: run-local-api | ||
uses: ./.github/actions/run-local-api | ||
with: | ||
e2e_test_token: some-token | ||
# As per https://stackoverflow.com/q/65497331/421808 172.17.0.1 seems like the only way to resolve host DB | ||
database_url: postgres://postgres:postgres@172.17.0.1:5432/flagsmith | ||
disable_analytics_features: true | ||
|
||
- name: Run E2E tests against local | ||
uses: ./.github/actions/e2e-tests | ||
env: | ||
E2E_CONCURRENCY: ${{ inputs.concurrency }} | ||
with: | ||
e2e_test_token: some-token | ||
slack_token: ${{ inputs.slack_token }} | ||
environment: local | ||
tests: ${{ inputs.tests }} | ||
|
||
- name: Output API container status and logs | ||
if: failure() | ||
env: | ||
API_CONTAINER_ID: ${{ steps.run-local-api.outputs.containerId }} | ||
run: | | ||
docker inspect $API_CONTAINER_ID | jq '.[0].State' | ||
docker logs $API_CONTAINER_ID | ||
shell: bash |
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
name: Run E2E tests in docker unified environment | ||
description: Run the E2E tests against docker unified environment | ||
|
||
inputs: | ||
github_actor: | ||
description: Github actor | ||
required: true | ||
github_token: | ||
description: Github token | ||
required: true | ||
e2e_test_token_staging: | ||
description: The staging test token. | ||
required: true | ||
|
||
runs: | ||
using: composite | ||
|
||
steps: | ||
- name: Set up Docker Buildx | ||
uses: docker/setup-buildx-action@v2 | ||
|
||
- name: Expose GitHub Runtime | ||
uses: crazy-max/ghaction-github-runtime@v2 | ||
|
||
- name: Login to GitHub Container Registry | ||
uses: docker/login-action@v2 | ||
with: | ||
registry: ghcr.io | ||
username: ${{ inputs.github_actor }} | ||
password: ${{ inputs.github_token }} | ||
|
||
- name: Build docker-compose with unified-image | ||
working-directory: frontend | ||
env: | ||
E2E_TEST_TOKEN_STAGING: ${{ inputs.e2e_test_token_staging }} | ||
ENV: staging | ||
STATIC_ASSET_CDN_URL: / | ||
run: | | ||
docker buildx bake -f docker-compose-e2e-tests.yml --load | ||
shell: bash |
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
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
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
Oops, something went wrong.
b1d3323
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Successfully deployed to the following URLs:
docs – ./docs
docs-flagsmith.vercel.app
docs.flagsmith.com
docs-git-main-flagsmith.vercel.app
docs.bullet-train.io
b1d3323
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Successfully deployed to the following URLs:
flagsmith-frontend-preview – ./frontend
flagsmith-frontend-production-native.vercel.app
flagsmith-frontend-preview-flagsmith.vercel.app
flagsmith-frontend-preview-git-main-flagsmith.vercel.app
b1d3323
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Successfully deployed to the following URLs:
flagsmith-frontend-staging – ./frontend
flagsmith-staging-frontend.vercel.app
flagsmith-frontend-staging-git-main-flagsmith.vercel.app
flagsmith-frontend-staging-flagsmith.vercel.app
staging.flagsmith.com