diff --git a/.ibm/pipelines/env_variables.sh b/.ibm/pipelines/env_variables.sh index 11bb50ad45..16d4d71405 100755 --- a/.ibm/pipelines/env_variables.sh +++ b/.ibm/pipelines/env_variables.sh @@ -23,6 +23,7 @@ NAME_SPACE_RBAC="${NAME_SPACE_RBAC:-showcase-rbac}" NAME_SPACE_RUNTIME="${NAME_SPACE_RUNTIME:-showcase-runtime}" NAME_SPACE_POSTGRES_DB="${NAME_SPACE_POSTGRES_DB:-postgress-external-db}" NAME_SPACE_RDS="showcase-rds-nightly" +NAME_SPACE_SANITY_PLUGINS_CHECK="showcase-sanity-plugins" OPERATOR_MANAGER='rhdh-operator' CHART_VERSION="2.15.2" # Fixed version should be used for release branches. GITHUB_APP_APP_ID=$(cat /tmp/secrets/GITHUB_APP_3_APP_ID) diff --git a/.ibm/pipelines/jobs/periodic.sh b/.ibm/pipelines/jobs/periodic.sh index 44a07b6103..9ec9a0d20d 100644 --- a/.ibm/pipelines/jobs/periodic.sh +++ b/.ibm/pipelines/jobs/periodic.sh @@ -13,12 +13,13 @@ handle_nightly() { cluster_setup initiate_deployments - # add_sanity_plugins_check + run_sanity_plugins_check deploy_test_backstage_provider "${NAME_SPACE}" run_standard_deployment_tests - run_rds_deployment_tests - # run_runtime_config_change_tests + run_sanity_plugins_check +# run_rds_deployment_tests + run_runtime_config_change_tests } @@ -54,12 +55,21 @@ run_runtime_config_change_tests() { check_and_test "${RELEASE_NAME}" "${NAME_SPACE_RUNTIME}" "${runtime_url}" } -add_sanity_plugins_check() { - helm upgrade -i "${RELEASE_NAME}" -n "${NAME_SPACE}" \ - "${HELM_REPO_NAME}/${HELM_IMAGE_NAME}" --version "${CHART_VERSION}" \ - -f "${DIR}/value_files/${HELM_CHART_VALUE_FILE_NAME}" \ - -f "${DIR}/value_files/sanity-check-plugins.yaml" \ - --set global.clusterRouterBase="${K8S_CLUSTER_ROUTER_BASE}" \ - --set upstream.backstage.image.repository="${QUAY_REPO}" \ - --set upstream.backstage.image.tag="${TAG_NAME}" +run_sanity_plugins_check() { + configure_namespace "${NAME_SPACE_SANITY_PLUGINS_CHECK}" + uninstall_helmchart "${NAME_SPACE_SANITY_PLUGINS_CHECK}" "${RELEASE_NAME}" + oc apply -f "$DIR/resources/redis-cache/redis-deployment.yaml" --namespace="${NAME_SPACE_SANITY_PLUGINS_CHECK}" + local sanity_plugins_url="https://${RELEASE_NAME}-backstage-${NAME_SPACE_SANITY_PLUGINS_CHECK}.${K8S_CLUSTER_ROUTER_BASE}" + apply_yaml_files "${DIR}" "${NAME_SPACE_SANITY_PLUGINS_CHECK}" "${sanity_plugins_url}" + + helm upgrade -i "${RELEASE_NAME}" \ + -n "${NAME_SPACE_SANITY_PLUGINS_CHECK}" "${HELM_REPO_NAME}/${HELM_IMAGE_NAME}" \ + --version "${CHART_VERSION}" \ + -f "${DIR}/value_files/${HELM_CHART_VALUE_FILE_NAME}" \ + -f "${DIR}/value_files/sanity-check-plugins.yaml" \ + --set global.clusterRouterBase="${K8S_CLUSTER_ROUTER_BASE}" \ + --set upstream.backstage.image.repository="${QUAY_REPO}" \ + --set upstream.backstage.image.tag="${TAG_NAME}" + + check_and_test "${RELEASE_NAME}" "smoke-tests" "${sanity_plugins_url}" } diff --git a/.ibm/pipelines/openshift-ci-tests.sh b/.ibm/pipelines/openshift-ci-tests.sh index fa3770570f..2a341cb5d8 100755 --- a/.ibm/pipelines/openshift-ci-tests.sh +++ b/.ibm/pipelines/openshift-ci-tests.sh @@ -45,6 +45,10 @@ for SCRIPT in "${SCRIPTS[@]}"; do echo "Loaded ${SCRIPT}" done +export JOB_NAME=periodic +#export K8S_CLUSTER_URL='https://api.alxdq5slv4a572c9df.eastus.aroapp.io:6443' +#export K8S_CLUSTER_TOKEN=${K8S_CLUSTER_TOKEN_TEMPORARY} + main() { echo "Log file: ${LOGFILE}" echo "JOB_NAME : $JOB_NAME" diff --git a/.ibm/pipelines/value_files/sanity-check-plugins.yaml b/.ibm/pipelines/value_files/sanity-check-plugins.yaml index 1484741d5e..e4bef4ab59 100644 --- a/.ibm/pipelines/value_files/sanity-check-plugins.yaml +++ b/.ibm/pipelines/value_files/sanity-check-plugins.yaml @@ -14,8 +14,27 @@ global: disabled: false - package: ./dynamic-plugins/dist/roadiehq-backstage-plugin-argo-cd-backend-dynamic disabled: false + pluginConfig: + argocd: + username: "temp" + password: "temp" + appLocatorMethods: + - type: 'config' + instances: + - name: argoInstance1 + url: "temp" - package: ./dynamic-plugins/dist/roadiehq-scaffolder-backend-argocd-dynamic - disabled: false + disabled: true + pluginConfig: + argocd: + username: "temp" + password: "temp" + appLocatorMethods: + - type: 'config' + instances: + - name: argoInstance1 + url: "temp" + token: "temp" - package: ./dynamic-plugins/dist/roadiehq-backstage-plugin-argo-cd disabled: false - package: ./dynamic-plugins/dist/backstage-community-plugin-redhat-argocd @@ -30,6 +49,13 @@ global: disabled: false - package: ./dynamic-plugins/dist/backstage-community-plugin-jenkins-backend-dynamic disabled: false + pluginConfig: + jenkins: + instances: + - name: default + baseUrl: 'temp' + username: 'temp' + apiKey: 'temp' - package: ./dynamic-plugins/dist/backstage-community-plugin-jenkins disabled: false - package: ./dynamic-plugins/dist/backstage-plugin-notifications @@ -38,18 +64,27 @@ global: disabled: false - package: ./dynamic-plugins/dist/backstage-plugin-notifications-backend-module-email-dynamic disabled: false + pluginConfig: + notifications: + processors: + email: + transportConfig: + sender: 'temp' - package: ./dynamic-plugins/dist/backstage-plugin-signals-backend-dynamic disabled: false - package: ./dynamic-plugins/dist/backstage-plugin-signals disabled: false - package: ./dynamic-plugins/dist/backstage-community-plugin-sonarqube-backend-dynamic disabled: false - - package: ./dynamic-plugins/dist/backstage-community-plugin-sonarqube - disabled: false pluginConfig: sonarqube: - baseUrl: 'temp' - apiKey: 'temp' + instances: + - name: default + instanceKey: 'mySonarqube' + baseUrl: 'https://default-sonarqube.example.com' + apiKey: '123456789abcdef0123456789abcedf012' + - package: ./dynamic-plugins/dist/backstage-community-plugin-sonarqube + disabled: false - package: ./dynamic-plugins/dist/red-hat-developer-hub-backstage-plugin-dynamic-home-page disabled: false - package: ./dynamic-plugins/dist/backstage-plugin-techdocs-backend-dynamic @@ -100,28 +135,22 @@ global: authorization: "temp" - package: ./dynamic-plugins/dist/backstage-community-plugin-3scale-backend-dynamic disabled: false + pluginConfig: + catalog: + providers: + threeScaleApiEntity: + default: + baseUrl: 'temp' + accessToken: 'temp' - package: ./dynamic-plugins/dist/backstage-plugin-scaffolder-backend-module-bitbucket-cloud-dynamic disabled: false - - package: ./dynamic-plugins/dist/backstage-plugin-catalog-backend-module-bitbucket-cloud-dynamic - disabled: false - - package: ./dynamic-plugins/dist/backstage-plugin-scaffolder-backend-module-bitbucket-server-dynamic - disabled: false - - package: ./dynamic-plugins/dist/backstage-plugin-catalog-backend-module-bitbucket-server-dynamic - disabled: false pluginConfig: - # https://backstage.io/docs/integrations/bitbucketServer/discovery#configuration + # https://backstage.io/docs/integrations/bitbucketCloud/discovery#configuration catalog: providers: - bitbucketServer: + bitbucketCloud: default: # identifies your ingested dataset - host: 'temp' - schedule: - frequency: - minutes: 30 - initialDelay: - minutes: 1 - timeout: - minutes: 3 + workspace: 'temp' - package: ./dynamic-plugins/dist/backstage-community-plugin-dynatrace disabled: false - package: ./dynamic-plugins/dist/roadiehq-backstage-plugin-jira diff --git a/e2e-tests/package.json b/e2e-tests/package.json index 67d2dc0397..7b9cdecc2d 100644 --- a/e2e-tests/package.json +++ b/e2e-tests/package.json @@ -18,6 +18,7 @@ "showcase-op-rbac-nightly": "playwright test --project=showcase-operator-rbac", "showcase-rds-nightly": "playwright test --project=postgres-health-check", "showcase-runtime": "playwright test --project=showcase-runtime", + "smoke-tests": "playwright test --project=smoke-tests", "lint:check": "eslint . --ext .js,.ts", "lint:fix": "eslint . --ext .js,.ts --fix", "postinstall": "playwright install", diff --git a/e2e-tests/playwright.config.ts b/e2e-tests/playwright.config.ts index 319daf7c3d..9c113c3c38 100644 --- a/e2e-tests/playwright.config.ts +++ b/e2e-tests/playwright.config.ts @@ -153,5 +153,16 @@ export default defineConfig({ ...useCommonDeviceAndViewportConfig, testMatch: ["**/playwright/e2e/configuration-test/config-map.spec.ts"], }, + { + name: "smoke-tests", + ...useCommonDeviceAndViewportConfig, + testMatch: [ + "**/playwright/e2e-tests/catalog-timestamp.spec.ts", + "**/playwright/e2e-tests/plugins/bulk-import.spec.ts", + "**/playwright/e2e-tests/plugins/http-request.spec.ts", + "**/playwright/e2e-tests/plugins/quick-access-and-tech-radar.spec.ts", + "**/playwright/e2e-tests/plugins/frontend/sidebar.spec.ts", + ], + }, ], }); diff --git a/e2e-tests/playwright/e2e/audit-log/catalog.spec.ts b/e2e-tests/playwright/e2e/audit-log/catalog.spec.ts index 45e985c1bb..a217e4930c 100644 --- a/e2e-tests/playwright/e2e/audit-log/catalog.spec.ts +++ b/e2e-tests/playwright/e2e/audit-log/catalog.spec.ts @@ -4,7 +4,7 @@ import { UIhelper } from "../../utils/ui-helper"; import { LogUtils } from "./log-utils"; import { CatalogImport } from "../../support/pages/catalog-import"; -test.describe.skip("Audit Log check for Catalog Plugin", () => { +test.describe("Audit Log check for Catalog Plugin", () => { let uiHelper: UIhelper; let common: Common; let catalogImport: CatalogImport;