From 6949da2e6b60ac5fb3cbba1bdee58cc8b2ec2ba3 Mon Sep 17 00:00:00 2001 From: Will Smith Date: Thu, 25 Apr 2024 09:57:41 -0700 Subject: [PATCH] Upmerge v0.32 to edge (#1293) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Make env configurable (#1046) Signed-off-by: Reshma Abdul Rahim * Adding test AKS workflow to v0.32 (#1052) * Run functional tests every 2 hours and add another workflow that runs… (#1020) * Run functional tests every 2 hours and add another workflow that runs the tests on AKS instead of k3d Signed-off-by: ytimocin * Triggering workflow Signed-off-by: ytimocin --------- Signed-off-by: ytimocin * Removing the run of the AKS workflow on PRs (#1051) Signed-off-by: ytimocin * Update the timeout (30s) for Playwright Signed-off-by: ytimocin --------- Signed-off-by: ytimocin * Use retry and update eshop playwright tests to wait for the catalog to appear (#1213) Signed-off-by: ytimocin --------- Signed-off-by: Reshma Abdul Rahim Signed-off-by: ytimocin Signed-off-by: willdavsmith Co-authored-by: Reshma Abdul Rahim <61033581+Reshrahim@users.noreply.github.com> Co-authored-by: Yetkin Timocin --- .github/scripts/cleanup-cluster.sh | 7 ++++--- .github/workflows/test-aks.yaml | 17 +++++++++++------ playwright/package-lock.json | 8 ++++---- playwright/package.json | 2 +- 4 files changed, 20 insertions(+), 14 deletions(-) diff --git a/.github/scripts/cleanup-cluster.sh b/.github/scripts/cleanup-cluster.sh index 76356a09..fcecaa56 100755 --- a/.github/scripts/cleanup-cluster.sh +++ b/.github/scripts/cleanup-cluster.sh @@ -18,7 +18,7 @@ set -e -echo "cleaning up cluster" +echo "Cleaning up cluster" # Delete all test resources in queuemessages. if kubectl get crd queuemessages.ucp.dev >/dev/null 2>&1; then @@ -39,9 +39,10 @@ if kubectl get crd resources.ucp.dev >/dev/null 2>&1; then fi # Delete all test namespaces. -echo "delete all test namespaces" +# Any namespace that is not in the list below will be deleted. +echo "Delete all test namespaces" namespaces=$(kubectl get namespace | - grep -E '^containers.*|^dapr |^dapr-dapr.*|^demo.*|^demo-demo-.*|^eshop-containers.*|^volumes.*|^volumes-myapp.*|^azure.*' | + grep -vE '(radius-system|kube-system|kube-public|kube-node-lease|gatekeeper-system|default|dapr-system|cert-manager)' | awk '{print $1}') for ns in $namespaces; do if [ -z "$ns" ]; then diff --git a/.github/workflows/test-aks.yaml b/.github/workflows/test-aks.yaml index 40ec06cd..390a6d4d 100644 --- a/.github/workflows/test-aks.yaml +++ b/.github/workflows/test-aks.yaml @@ -15,6 +15,11 @@ on: paths: - "samples/**" - ".github/workflows/**" + pull_request: + types: [opened, synchronize, reopened] + branches: + - v*.* + - edge schedule: # Run every 2 hours - cron: "0 */2 * * *" env: @@ -38,7 +43,7 @@ jobs: - name: Setup Node uses: actions/setup-node@v3 with: - node-version: 16 + node-version: 20 - name: az CLI login run: | az login --service-principal \ @@ -107,20 +112,20 @@ jobs: - name: eshop-azure os: ubuntu-latest-m runOnPullRequest: true - app: eshop + app: eshop-azure env: azure path: ./samples/eshop/eshop.bicep uiTestFile: tests/eshop/eshop.app.spec.ts - deployArgs: -p environment='/planes/radius/local/resourceGroups/eshop-azure/providers/Applications.Core/environments/azure' + deployArgs: -p environment='/planes/radius/local/resourceGroups/eshop-azure/providers/Applications.Core/environments/azure' -p applicationName=eshop-azure credential: azure - name: eshop-aws os: ubuntu-latest-m runOnPullRequest: true - app: eshop + app: eshop-aws env: aws path: ./samples/eshop/eshop.bicep uiTestFile: tests/eshop/eshop.app.spec.ts - deployArgs: -p environment='/planes/radius/local/resourceGroups/eshop-aws/providers/Applications.Core/environments/aws' + deployArgs: -p environment='/planes/radius/local/resourceGroups/eshop-aws/providers/Applications.Core/environments/aws' -p applicationName=eshop-aws credential: aws env: BRANCH: ${{ github.base_ref || github.ref_name }} @@ -159,7 +164,7 @@ jobs: if: steps.gen-id.outputs.RUN_TEST == 'true' uses: actions/setup-node@v3 with: - node-version: 16 + node-version: 20 - name: az CLI login if: steps.gen-id.outputs.RUN_TEST == 'true' run: | diff --git a/playwright/package-lock.json b/playwright/package-lock.json index 584c5d37..91d85551 100644 --- a/playwright/package-lock.json +++ b/playwright/package-lock.json @@ -13,7 +13,7 @@ }, "devDependencies": { "@playwright/test": "^1.43.0", - "@types/node": "^20.12.5", + "@types/node": "^20.12.6", "@types/uuid": "^9.0.8", "typescript": "^5.4.4" } @@ -34,9 +34,9 @@ } }, "node_modules/@types/node": { - "version": "20.12.5", - "resolved": "https://registry.npmjs.org/@types/node/-/node-20.12.5.tgz", - "integrity": "sha512-BD+BjQ9LS/D8ST9p5uqBxghlN+S42iuNxjsUGjeZobe/ciXzk2qb1B6IXc6AnRLS+yFJRpN2IPEHMzwspfDJNw==", + "version": "20.12.6", + "resolved": "https://registry.npmjs.org/@types/node/-/node-20.12.6.tgz", + "integrity": "sha512-3KurE8taB8GCvZBPngVbp0lk5CKi8M9f9k1rsADh0Evdz5SzJ+Q+Hx9uHoFGsLnLnd1xmkDQr2hVhlA0Mn0lKQ==", "dev": true, "dependencies": { "undici-types": "~5.26.4" diff --git a/playwright/package.json b/playwright/package.json index a460819b..f29f910b 100644 --- a/playwright/package.json +++ b/playwright/package.json @@ -9,7 +9,7 @@ "license": "ISC", "devDependencies": { "@playwright/test": "^1.43.0", - "@types/node": "^20.12.5", + "@types/node": "^20.12.6", "@types/uuid": "^9.0.8", "typescript": "^5.4.4" },