CLD-7074 Implement full E2E tests on Github Actions (#26093)
* Move license setting from env var to mmctl upload * Extract common E2E steps * Add E2E fulltests * Fix plugin_startup_fail_spec.js, timeout runners, fix local dashboard run * Implement reporting script and job * Bump artifact related actions * Fix E2E variable generator script * Skip reporting steps if not required * Get rid of deprecation warnings * Fix inbucket hostname parameter * Support arbitrary refs in test template * Fix cycle BRANCH var for non-PR commits --------- Co-authored-by: Mattermost Build <build@mattermost.com>
Этот коммит содержится в:
коммит произвёл
GitHub
родитель
c82352c90c
Коммит
d7a77d8c42
83
.github/workflows/e2e-fulltests-ci.yml
поставляемый
Обычный файл
83
.github/workflows/e2e-fulltests-ci.yml
поставляемый
Обычный файл
@@ -0,0 +1,83 @@
|
||||
---
|
||||
name: E2E Tests
|
||||
on:
|
||||
# For PRs, this workflow gets triggered from the Argo Events platform.
|
||||
# Check the following repo for details: https://github.com/mattermost/delivery-platform
|
||||
workflow_dispatch:
|
||||
inputs:
|
||||
ref:
|
||||
type: string
|
||||
required: false
|
||||
REPORT_TYPE:
|
||||
type: choice
|
||||
description: The context this report is being generated in
|
||||
options:
|
||||
- PR
|
||||
- RELEASE
|
||||
- MASTER
|
||||
- MASTER_UNSTABLE
|
||||
- CLOUD
|
||||
- CLOUD_UNSTABLE
|
||||
- NONE
|
||||
default: NONE
|
||||
|
||||
jobs:
|
||||
generate-test-variables:
|
||||
runs-on: ubuntu-22.04
|
||||
outputs:
|
||||
status_check_context: "${{ steps.generate.outputs.status_check_context }}"
|
||||
workers_number: "${{ steps.generate.outputs.workers_number }}"
|
||||
ENABLED_DOCKER_SERVICES: "${{ steps.generate.outputs.ENABLED_DOCKER_SERVICES }}"
|
||||
TEST_FILTER: "${{ steps.generate.outputs.TEST_FILTER }}"
|
||||
env:
|
||||
# We could exclude the @smoke group for PRs, but then we wouldn't have it in the report
|
||||
TEST_FILTER_PR: >-
|
||||
--stage="@prod"
|
||||
--excludeGroup="@te_only,@cloud_only,@high_availability"
|
||||
--sortFirst="@compliance_export,@elasticsearch,@ldap_group,@ldap"
|
||||
--sortLast="@saml,@keycloak,@plugin,@plugins_uninstall,@mfa,@license_removal"
|
||||
steps:
|
||||
- name: ci/generate-test-variables
|
||||
id: generate
|
||||
shell: bash
|
||||
run: |
|
||||
case "${{ inputs.REPORT_TYPE }}" in
|
||||
NONE | PR)
|
||||
echo "status_check_context=E2E Tests/test" >> $GITHUB_OUTPUT
|
||||
echo "workers_number=20" >> $GITHUB_OUTPUT
|
||||
echo "ENABLED_DOCKER_SERVICES=postgres inbucket minio openldap elasticsearch keycloak" >> $GITHUB_OUTPUT
|
||||
echo "TEST_FILTER=$TEST_FILTER_PR" >> $GITHUB_OUTPUT
|
||||
;;
|
||||
*)
|
||||
# TODO implement other test types, in the future
|
||||
echo "Fatal: unimplemented test type. Aborting."
|
||||
exit 1
|
||||
esac
|
||||
|
||||
e2e-fulltest:
|
||||
needs:
|
||||
- generate-test-variables
|
||||
uses: ./.github/workflows/e2e-tests-ci-template.yml
|
||||
strategy:
|
||||
matrix:
|
||||
type:
|
||||
- name: PR
|
||||
with:
|
||||
ref: "${{ inputs.ref || github.sha }}"
|
||||
status_check_context: "${{ needs.generate-test-variables.outputs.status_check_context }}"
|
||||
workers_number: "${{ needs.generate-test-variables.outputs.workers_number }}"
|
||||
testcase_failure_fatal: false
|
||||
run_preflight_checks: false
|
||||
enable_reporting: true
|
||||
ENABLED_DOCKER_SERVICES: "${{ needs.generate-test-variables.outputs.ENABLED_DOCKER_SERVICES }}"
|
||||
TEST_FILTER: "${{ needs.generate-test-variables.outputs.TEST_FILTER }}"
|
||||
REPORT_TYPE: "${{ inputs.REPORT_TYPE }}"
|
||||
secrets:
|
||||
MM_LICENSE: "${{ secrets.MM_E2E_TEST_LICENSE_ONPREM_ENT }}"
|
||||
AUTOMATION_DASHBOARD_URL: "${{ secrets.MM_E2E_AUTOMATION_DASHBOARD_URL }}"
|
||||
AUTOMATION_DASHBOARD_TOKEN: "${{ secrets.MM_E2E_AUTOMATION_DASHBOARD_TOKEN }}"
|
||||
PUSH_NOTIFICATION_SERVER: "${{ secrets.MM_E2E_PUSH_NOTIFICATION_SERVER }}"
|
||||
REPORT_WEBHOOK_URL: "${{ secrets.MM_E2E_REPORT_WEBHOOK_URL }}"
|
||||
### These are disabled until release tests are implemented
|
||||
#REPORT_TM4J_API_KEY: "${{ secrets.MM_E2E_TM4J_API_KEY }}"
|
||||
#REPORT_TEST_CYCLE_LINK_PREFIX: "${{ secrets.MM_E2E_TEST_CYCLE_LINK_PREFIX }}"
|
||||
Ссылка в новой задаче
Block a user