test(ui): avoid provider connection in no-scan flow

This commit is contained in:
Alan Buscaglia
2026-06-29 23:19:09 +02:00
parent 70d89377ce
commit 196647bf00
2 changed files with 73 additions and 75 deletions
+5 -7
View File
@@ -1028,13 +1028,11 @@ export class ProvidersPage extends BasePage {
return;
}
// Provider-add E2E validates credentials and provider persistence only.
// Launching one scan per provider made CI noisy and overloaded the backend;
// scan execution itself is covered by scans.spec.ts.
if (await testConnectionButton.isVisible().catch(() => false)) {
await testConnectionButton.click();
await this.waitForProviderReadyToClose(timeout);
} else {
// Provider-add E2E validates credential persistence only. Reaching the
// connection step is enough; do not click "Continue"/"Check connection"
// because that performs provider-specific connectivity checks covered by
// dedicated scan/connection flows and can hang on external services.
if (!(await testConnectionButton.isVisible().catch(() => false))) {
await expect(launchStepReady).toBeVisible({ timeout });
}
+68 -68
View File
@@ -32,14 +32,14 @@
4. Fill provider details (account ID and alias)
5. Select "credentials" authentication type
6. Fill static credentials (access key and secret key)
7. Confirm provider connection without launching a scan
7. Confirm provider setup without launching a scan
8. Verify return to Providers page
9. Verify provider exists in Providers table
### Expected Result
- AWS provider successfully added with static credentials
- Provider connection validated without launching a scan
- Provider credentials saved without launching a scan
- User returned to Providers page
- Provider appears in Providers table with the expected UID
@@ -48,8 +48,8 @@
- Provider page loads correctly
- Connect account page displays AWS option
- Credentials form accepts static credentials
- Launch step appears
- Successful return to Providers page after closing the launch step
- Connection or launch step appears
- Successful return to Providers page after closing the wizard
- Provider exists in Providers table (verified by account ID)
- Provider UID matches the expected value
@@ -88,14 +88,14 @@
4. Fill provider details (account ID and alias)
5. Select "role" authentication type
6. Fill role credentials (access key, secret key, and role ARN)
7. Confirm provider connection without launching a scan
7. Confirm provider setup without launching a scan
8. Verify return to Providers page
9. Verify provider exists in Providers table
### Expected Result
- AWS provider successfully added with role credentials
- Provider connection validated without launching a scan
- Provider credentials saved without launching a scan
- User returned to Providers page
- Provider appears in Providers table with the expected UID
@@ -104,8 +104,8 @@
- Provider page loads correctly
- Connect account page displays AWS option
- Role credentials form accepts all required fields
- Launch step appears
- Successful return to Providers page after closing the launch step
- Connection or launch step appears
- Successful return to Providers page after closing the wizard
- Provider exists in Providers table (verified by account ID)
- Provider UID matches the expected value
@@ -144,14 +144,14 @@
3. Select Azure provider type
4. Fill provider details (subscription ID and alias)
5. Fill Azure credentials (client ID, client secret, tenant ID)
6. Confirm provider connection without launching a scan
6. Confirm provider setup without launching a scan
7. Verify return to Providers page
8. Verify provider exists in Providers table
### Expected Result
- Azure provider successfully added with static credentials
- Provider connection validated without launching a scan
- Provider credentials saved without launching a scan
- User returned to Providers page
- Provider appears in Providers table with the expected UID
@@ -160,8 +160,8 @@
- Provider page loads correctly
- Connect account page displays Azure option
- Azure credentials form accepts all required fields
- Launch step appears
- Successful return to Providers page after closing the launch step
- Connection or launch step appears
- Successful return to Providers page after closing the wizard
- Provider exists in Providers table (verified by subscription ID)
- Provider UID matches the expected value
@@ -201,14 +201,14 @@
4. Fill provider details (domain ID and alias)
5. Select static credentials type
6. Fill M365 credentials (client ID, client secret, tenant ID)
7. Confirm provider connection without launching a scan
7. Confirm provider setup without launching a scan
8. Verify return to Providers page
9. Verify provider exists in Providers table
### Expected Result
- M365 provider successfully added with static credentials
- Provider connection validated without launching a scan
- Provider credentials saved without launching a scan
- User returned to Providers page
- Provider appears in Providers table with the expected UID
@@ -217,8 +217,8 @@
- Provider page loads correctly
- Connect account page displays M365 option
- M365 credentials form accepts all required fields
- Launch step appears
- Successful return to Providers page after closing the launch step
- Connection or launch step appears
- Successful return to Providers page after closing the wizard
- Provider exists in Providers table (verified by domain ID)
- Provider UID matches the expected value
@@ -258,14 +258,14 @@
4. Fill provider details (domain ID and alias)
5. Select certificate credentials type
6. Fill M365 certificate credentials (client ID, tenant ID, certificate content)
7. Confirm provider connection without launching a scan
7. Confirm provider setup without launching a scan
8. Verify return to Providers page
9. Verify provider exists in Providers table
### Expected Result
- M365 provider successfully added with certificate credentials
- Provider connection validated without launching a scan
- Provider credentials saved without launching a scan
- User returned to Providers page
- Provider appears in Providers table with the expected UID
@@ -274,8 +274,8 @@
- Provider page loads correctly
- Connect account page displays M365 option
- Certificate credentials form accepts all required fields
- Launch step appears
- Successful return to Providers page after closing the launch step
- Connection or launch step appears
- Successful return to Providers page after closing the wizard
- Provider exists in Providers table (verified by domain ID)
- Provider UID matches the expected value
@@ -316,14 +316,14 @@
4. Fill provider details (context and alias)
5. Verify credentials page is loaded
6. Fill Kubernetes credentials (kubeconfig content)
7. Confirm provider connection without launching a scan
7. Confirm provider setup without launching a scan
8. Verify return to Providers page
9. Verify provider exists in Providers table
### Expected Result
- Kubernetes provider successfully added with kubeconfig content
- Provider connection validated without launching a scan
- Provider credentials saved without launching a scan
- User returned to Providers page
- Provider appears in Providers table with the expected UID
@@ -334,8 +334,8 @@
- Provider details form accepts context and alias
- Credentials page loads with kubeconfig content field
- Kubeconfig content is properly filled in the correct field
- Launch step appears
- Successful return to Providers page after closing the launch step
- Connection or launch step appears
- Successful return to Providers page after closing the wizard
- Provider exists in Providers table (verified by context)
- Provider UID matches the expected value
@@ -377,14 +377,14 @@
4. Fill provider details (project ID and alias)
5. Select service account credentials type
6. Fill GCP service account key credentials
7. Confirm provider connection without launching a scan
7. Confirm provider setup without launching a scan
8. Verify return to Providers page
9. Verify provider exists in Providers table
### Expected Result
- GCP provider successfully added with service account key
- Provider connection validated without launching a scan
- Provider credentials saved without launching a scan
- User returned to Providers page
- Provider appears in Providers table with the expected UID
@@ -395,8 +395,8 @@
- Provider details form accepts project ID and alias
- Service account credentials page loads with service account key field
- Service account key is properly filled in the correct field
- Launch step appears
- Successful return to Providers page after closing the launch step
- Connection or launch step appears
- Successful return to Providers page after closing the wizard
- Provider exists in Providers table (verified by project ID)
- Provider UID matches the expected value
@@ -439,14 +439,14 @@
4. Fill provider details (username and alias)
5. Select personal access token credentials type
6. Fill GitHub personal access token credentials
7. Confirm provider connection without launching a scan
7. Confirm provider setup without launching a scan
8. Verify return to Providers page
9. Verify provider exists in Providers table
### Expected Result
- GitHub provider successfully added with personal access token
- Provider connection validated without launching a scan
- Provider credentials saved without launching a scan
- User returned to Providers page
- Provider appears in Providers table with the expected UID
@@ -457,8 +457,8 @@
- Provider details form accepts username and alias
- Personal access token credentials page loads with token field
- Personal access token is properly filled in the correct field
- Launch step appears
- Successful return to Providers page after closing the launch step
- Connection or launch step appears
- Successful return to Providers page after closing the wizard
- Provider exists in Providers table (verified by username)
- Provider UID matches the expected value
@@ -499,14 +499,14 @@
4. Fill provider details (username and alias)
5. Select GitHub App credentials type
6. Fill GitHub App credentials (App ID and private key)
7. Confirm provider connection without launching a scan
7. Confirm provider setup without launching a scan
8. Verify return to Providers page
9. Verify provider exists in Providers table
### Expected Result
- GitHub provider successfully added with GitHub App credentials
- Provider connection validated without launching a scan
- Provider credentials saved without launching a scan
- User returned to Providers page
- Provider appears in Providers table with the expected UID
@@ -517,8 +517,8 @@
- Provider details form accepts username and alias
- GitHub App credentials page loads with App ID and private key fields
- GitHub App credentials are properly filled in the correct fields
- Launch step appears
- Successful return to Providers page after closing the launch step
- Connection or launch step appears
- Successful return to Providers page after closing the wizard
- Provider exists in Providers table (verified by username)
- Provider UID matches the expected value
@@ -560,14 +560,14 @@
4. Fill provider details (organization name and alias)
5. Select personal access token credentials type
6. Fill GitHub organization personal access token credentials
7. Confirm provider connection without launching a scan
7. Confirm provider setup without launching a scan
8. Verify return to Providers page
9. Verify provider exists in Providers table
### Expected Result
- GitHub provider successfully added with organization personal access token
- Provider connection validated without launching a scan
- Provider credentials saved without launching a scan
- User returned to Providers page
- Provider appears in Providers table with the expected UID
@@ -578,8 +578,8 @@
- Provider details form accepts organization name and alias
- Personal access token credentials page loads with token field
- Organization personal access token is properly filled in the correct field
- Launch step appears
- Successful return to Providers page after closing the launch step
- Connection or launch step appears
- Successful return to Providers page after closing the wizard
- Provider exists in Providers table (verified by organization name)
- Provider UID matches the expected value
@@ -621,14 +621,14 @@
5. Select "role" authentication type
6. Switch authentication method to "Use AWS SDK default credentials"
7. Fill role ARN using AWS SDK credential inputs
8. Confirm provider connection without launching a scan
8. Confirm provider setup without launching a scan
9. Verify return to Providers page
10. Verify provider exists in Providers table
### Expected Result
- AWS provider successfully added using AWS SDK default credentials to assume the role
- Provider connection validated without launching a scan
- Provider credentials saved without launching a scan
- User returned to Providers page
- Provider appears in Providers table with the expected UID
@@ -638,8 +638,8 @@
- Connect account page displays AWS option
- Credentials form exposes AWS SDK default authentication method
- Role ARN field accepts provided value when SDK method is selected
- Launch step appears
- Successful return to Providers page after closing the launch step
- Connection or launch step appears
- Successful return to Providers page after closing the wizard
- Provider exists in Providers table (verified by account ID)
- Provider UID matches the expected value
@@ -679,14 +679,14 @@
4. Fill provider details (tenancy ID and alias)
5. Verify OCI credentials page is loaded
6. Fill OCI credentials (user ID, fingerprint, key content, region)
7. Confirm provider connection without launching a scan
7. Confirm provider setup without launching a scan
8. Verify return to Providers page
9. Verify provider exists in Providers table
### Expected Result
- OCI provider successfully added with API Key credentials
- Provider connection validated without launching a scan
- Provider credentials saved without launching a scan
- User returned to Providers page
- Provider appears in Providers table with the expected UID
@@ -697,8 +697,8 @@
- Provider details form accepts tenancy ID and alias
- OCI credentials page loads
- Credentials form accepts all required fields (user ID, fingerprint, key content, region)
- Launch step appears
- Successful return to Providers page after closing the launch step
- Connection or launch step appears
- Successful return to Providers page after closing the wizard
- Provider exists in Providers table (verified by tenancy ID)
- Provider UID matches the expected value
@@ -798,14 +798,14 @@
6. Select static credentials type
7. Verify static credentials page is loaded
8. Fill AlibabaCloud credentials (access key ID and access key secret)
9. Confirm provider connection without launching a scan
9. Confirm provider setup without launching a scan
10. Verify return to Providers page
11. Verify provider exists in Providers table
### Expected Result
- AlibabaCloud provider successfully added with static credentials
- Provider connection validated without launching a scan
- Provider credentials saved without launching a scan
- User returned to Providers page
- Provider appears in Providers table with the expected UID
@@ -817,8 +817,8 @@
- Credentials page loads with credential type selection
- Static credentials page loads with access key ID and access key secret fields
- Static credentials are properly filled in the correct fields
- Launch step appears
- Successful return to Providers page after closing the launch step
- Connection or launch step appears
- Successful return to Providers page after closing the wizard
- Provider exists in Providers table (verified by account ID)
- Provider UID matches the expected value
@@ -860,14 +860,14 @@
6. Select RAM Role credentials type
7. Verify RAM Role credentials page is loaded
8. Fill AlibabaCloud RAM Role credentials (access key ID, access key secret, and role ARN)
9. Confirm provider connection without launching a scan
9. Confirm provider setup without launching a scan
10. Verify return to Providers page
11. Verify provider exists in Providers table
### Expected Result
- AlibabaCloud provider successfully added with RAM Role credentials
- Provider connection validated without launching a scan
- Provider credentials saved without launching a scan
- User returned to Providers page
- Provider appears in Providers table with the expected UID
@@ -879,8 +879,8 @@
- Credentials page loads with credential type selection
- RAM Role credentials page loads with access key ID, access key secret, and role ARN fields
- RAM Role credentials are properly filled in the correct fields
- Launch step appears
- Successful return to Providers page after closing the launch step
- Connection or launch step appears
- Successful return to Providers page after closing the wizard
- Provider exists in Providers table (verified by account ID)
- Provider UID matches the expected value
@@ -978,14 +978,14 @@
4. Fill provider details (customer ID and alias)
5. Verify Google Workspace credentials page is loaded
6. Fill Google Workspace credentials (customer ID, service account JSON, delegated user email)
7. Confirm provider connection without launching a scan
7. Confirm provider setup without launching a scan
8. Verify return to Providers page
9. Verify provider exists in Providers table
### Expected Result
- Google Workspace provider successfully added with Service Account credentials
- Provider connection validated without launching a scan
- Provider credentials saved without launching a scan
- User returned to Providers page
- Provider appears in Providers table with the expected UID
@@ -998,8 +998,8 @@
- Customer ID help text is visible with instructions on finding the Customer ID
- Service account JSON field accepts multi-line formatted JSON
- Delegated user email field validates email format
- Launch step appears
- Successful return to Providers page after closing the launch step
- Connection or launch step appears
- Successful return to Providers page after closing the wizard
- Provider exists in Providers table (verified by customer ID)
- Provider UID matches the expected value
@@ -1042,14 +1042,14 @@
4. Fill provider details (team ID and alias)
5. Verify Vercel credentials page is loaded
6. Fill Vercel credentials (API token)
7. Confirm provider connection without launching a scan
7. Confirm provider setup without launching a scan
8. Verify return to Providers page
9. Verify provider exists in Providers table
### Expected Result
- Vercel provider successfully added with API Token credentials
- Provider connection validated without launching a scan
- Provider credentials saved without launching a scan
- User returned to Providers page
- Provider appears in Providers table with the expected UID
@@ -1060,8 +1060,8 @@
- Provider details form accepts team ID and alias
- Credentials page loads with the API Token field
- API Token is properly filled in the correct (masked) field
- Launch step appears
- Successful return to Providers page after closing the launch step
- Connection or launch step appears
- Successful return to Providers page after closing the wizard
- Provider exists in Providers table (verified by team ID)
- Provider UID matches the expected value
@@ -1102,14 +1102,14 @@
4. Fill provider details (org domain and alias)
5. Verify Okta credentials page is loaded
6. Fill Okta credentials (client ID and PEM-encoded private key)
7. Confirm provider connection without launching a scan
7. Confirm provider setup without launching a scan
8. Verify return to Providers page
9. Verify provider exists in Providers table
### Expected Result
- Okta provider successfully added with OAuth 2.0 Private Key JWT credentials
- Provider connection validated successfully without launching a scan
- Provider credentials saved successfully without launching a scan
- User returned to Providers page
- Provider appears in Providers table with the expected UID
@@ -1120,8 +1120,8 @@
- Provider details form accepts org domain (Okta-managed domain, e.g. acme.okta.com) and alias
- Credentials page loads with Client ID input and Private Key textarea
- Credentials are properly filled in the correct fields
- Launch step appears
- Successful return to Providers page after closing the launch step
- Connection or launch step appears
- Successful return to Providers page after closing the wizard
- Provider exists in Providers table (verified by org domain)
### Notes