-
Notifications
You must be signed in to change notification settings - Fork 40
61 lines (61 loc) · 2.79 KB
/
RunE2ERCNightlies.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
name: RC E2E testing
on: workflow_dispatch
env:
AWS_S3_BUCKET_NAME: ${{ secrets.AWS_S3_BUCKET_NAME }}
AWS_REGION: ${{ secrets.AWS_REGION }}
AWS_IAM_ROLE_ARN: ${{ secrets.AWS_IAM_ROLE_ARN }}
permissions:
id-token: write # This is required for requesting the JWT
contents: read # This is required for actions/checkout
jobs:
RCArtifactsDownload:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
fetch-depth: 0
- name: Setup pnpm
uses: pnpm/action-setup@a3252b78c470c02df07e9d59298aecedc3ccdd6d # v3.0.0
- name: Setup node
uses: actions/setup-node@39370e3970a6d050c480ffad4ff0ed4d3fdee5af # v4.1.0
with:
node-version-file: ".nvmrc"
cache: "pnpm"
- name: Install dependencies
run: pnpm install
- name: Install Playwright Browsers
run: pnpm exec playwright install --with-deps chromium
- name: Setup AWS credentials
uses: aws-actions/configure-aws-credentials@97834a484a5ab3c40fa9e2eb40fcf8041105a573
with:
role-to-assume: ${{ env.AWS_IAM_ROLE_ARN }}
aws-region: ${{ env.AWS_REGION }}
# Download an artifact from AWS S3 bucket and use it to run E2E
- name: Run E2E using nightly artifacts
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
aws s3 cp s3://${{ env.AWS_S3_BUCKET_NAME }}/modelers/latest-studio-pro.json ./latest-studio-pro.json
URL=$(jq -r '.file' latest-studio-pro.json)
echo $URL
SP_VERSION=$(echo $URL | sed -E 's/.*(-([0-9]+\.[0-9]+\.[0-9]+\.[0-9]+)-).*/\2/')
echo $SP_VERSION
aws s3 cp s3://${{ env.AWS_S3_BUCKET_NAME }}/runtimes/mxbuild-${SP_VERSION}.tar.gz ${{ github.workspace }}/automation/run-e2e/docker/mxbuild.tar.gz
aws s3 cp s3://${{ env.AWS_S3_BUCKET_NAME }}/runtimes/mendix-${SP_VERSION}.tar.gz ${{ github.workspace }}/automation/run-e2e/docker/mendix.tar.gz
echo "Starting E2E testing execution..."
MENDIX_VERSION=$SP_VERSION RC=true pnpm -r --workspace-concurrency=1 run e2e
- name: "Fixing files permissions"
if: failure()
run: |
sudo find ${{ github.workspace }}/packages/* -type d -exec chmod 755 {} \;
sudo find ${{ github.workspace }}/packages/* -type f -exec chmod 644 {} \;
- name: "Archive test screenshot diff results"
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
if: failure()
with:
name: test-screenshot-results-1
path: |
${{ github.workspace }}/packages/**/**/test-results/**/*.png
${{ github.workspace }}/packages/**/**/test-results/**/*.zip
if-no-files-found: error