-
Notifications
You must be signed in to change notification settings - Fork 54
OBSINTA-1287: Agentic test iteration skills and Docker sandbox #879
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
DavidRajnoha
wants to merge
6
commits into
openshift:main
Choose a base branch
from
DavidRajnoha:infra/OBSINTA-1287-agentic-test-iteration
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
c8c6b38
docs: add agentic test iteration architecture and roadmap
DavidRajnoha 23376e4
feat: add test iteration skills and supporting scripts
DavidRajnoha 51f9df7
feat: add Docker-based sandbox for isolated Claude Code execution
DavidRajnoha 509ebb3
refactor: reorganize claude commands and docs directory structure
DavidRajnoha bf4fc65
feat: add productize-iterations and refactor-page-object skills, add …
a2310d2
fix: address CodeRabbit review remarks on PR #879
DavidRajnoha File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,92 @@ | ||
| --- | ||
| name: setup | ||
| description: Automated Cypress environment setup with direct configuration | ||
| parameters: [] | ||
| --- | ||
|
|
||
| # Cypress Environment Setup | ||
|
|
||
| This command sets up the Cypress testing environment by checking prerequisites, installing dependencies, and configuring environment variables. | ||
|
|
||
| ## Instructions for Claude | ||
|
|
||
| Follow these steps in order: | ||
|
|
||
| ### Step 1: Check Prerequisites | ||
|
|
||
| 1. **Check Node.js version** - Required: >= 18 | ||
| - Run `node --version` and verify it's >= 18 | ||
| - If not, inform the user they need to install Node.js 18 or higher | ||
|
|
||
| ### Step 2: Navigate and Install Dependencies | ||
|
|
||
| 1. **Navigate to the cypress directory**: | ||
| ```bash | ||
| cd web/cypress | ||
| ``` | ||
|
|
||
| 2. **Install npm dependencies**: | ||
| ```bash | ||
| npm install | ||
| ``` | ||
|
|
||
| ### Step 3: Create or Update Environment Configuration | ||
|
|
||
| **Important**: Do NOT run the interactive `configure-env.sh` script. Instead, create `export-env.sh` directly (in the `web/cypress/` directory from Step 2). | ||
|
|
||
| 1. Check if `export-env.sh` already exists | ||
| 2. If it exists, read it and show the current values to the user. Ask if they want to keep or update them. | ||
| 3. Look for cluster credentials in the following order: | ||
| - **Conversation context**: Check if the user already provided a console URL and kubeadmin password earlier in the conversation | ||
| - **Existing export-env.sh**: Reuse values from an existing file if the user confirms they're current | ||
| - **Ask the user directly**: If no credentials are found, ask the user to provide: | ||
| - Console URL (e.g., `https://console-openshift-console.apps.ci-ln-xxxxx.aws-4.ci.openshift.org`) | ||
| - Kubeadmin password | ||
| - **Do NOT proceed without credentials** — the file cannot be created with placeholder values | ||
| 4. Write the file directly: | ||
|
|
||
| ```bash | ||
| cat > export-env.sh << 'ENVEOF' | ||
| # shellcheck shell=bash | ||
| export CYPRESS_BASE_URL='<console-url>' | ||
| export CYPRESS_LOGIN_IDP='kube:admin' | ||
| export CYPRESS_LOGIN_USERS='kubeadmin:<password>' | ||
|
DavidRajnoha marked this conversation as resolved.
|
||
| export CYPRESS_KUBECONFIG_PATH='/tmp/kubeconfig' | ||
| export CYPRESS_SKIP_ALL_INSTALL='false' | ||
| export CYPRESS_SKIP_COO_INSTALL='false' | ||
| export CYPRESS_COO_UI_INSTALL='true' | ||
| export CYPRESS_SKIP_KBV_INSTALL='true' | ||
| export CYPRESS_KBV_UI_INSTALL='false' | ||
| export CYPRESS_TIMEZONE='UTC' | ||
| export CYPRESS_MOCK_NEW_METRICS='false' | ||
| export CYPRESS_SESSION='true' | ||
| export CYPRESS_DEBUG='false' | ||
| ENVEOF | ||
| ``` | ||
|
|
||
| 5. Set restrictive permissions (the file contains credentials): | ||
| ```bash | ||
| chmod 600 export-env.sh | ||
| ``` | ||
|
|
||
| Notes on the values: | ||
| - `CYPRESS_BASE_URL`: The OpenShift console URL from the cluster provisioning output | ||
| - `CYPRESS_LOGIN_USERS`: Format is `kubeadmin:<password>` using the password from cluster provisioning | ||
| - `CYPRESS_KUBECONFIG_PATH`: Use `/tmp/kubeconfig` when running in a Docker sandbox, or the actual path to kubeconfig on the host | ||
| - `CYPRESS_SKIP_ALL_INSTALL='false'`: Ensures operators get installed on first run | ||
| - `CYPRESS_COO_UI_INSTALL='true'`: Installs the Cluster Observability Operator UI plugin | ||
|
|
||
| ### Step 4: Verify the setup | ||
|
|
||
| Source the file and confirm the variables are set: | ||
|
|
||
| ```bash | ||
| source export-env.sh | ||
| echo "Base URL: $CYPRESS_BASE_URL" | ||
| ``` | ||
|
|
||
| ### Step 5: Inform the user | ||
|
|
||
| Let the user know the environment is configured and they can run tests using `/cypress:run`. | ||
|
|
||
| --- | ||
1 change: 1 addition & 0 deletions
1
.claude/commands/cypress/test-development/fixture-schema-reference.md
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| ../../../.cursor/commands/fixture-schema-reference.md |
1 change: 1 addition & 0 deletions
1
.claude/commands/cypress/test-development/generate-incident-fixture.md
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| ../../../.cursor/commands/generate-incident-fixture.md |
1 change: 1 addition & 0 deletions
1
.claude/commands/cypress/test-development/generate-regression-test.md
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| ../../../.cursor/commands/generate-regression-test.md |
1 change: 1 addition & 0 deletions
1
.claude/commands/cypress/test-development/refactor-regression-test.md
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| ../../../.cursor/commands/refactor-regression-test.md |
1 change: 1 addition & 0 deletions
1
.claude/commands/cypress/test-development/validate-incident-fixtures.md
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| ../../../.cursor/commands/validate-incident-fixtures.md |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.