@orion-qa/orion 3.0.0 → 3.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.claude/agents/automation-strategist.md +1 -0
- package/.claude/agents/change-agent.md +1 -0
- package/.claude/agents/codebase-analyst.md +2 -1
- package/.claude/agents/environment-discovery.md +1 -0
- package/.claude/agents/evidence-validator.md +1 -0
- package/.claude/agents/executor.md +1 -0
- package/.claude/agents/failure-analyst.md +2 -1
- package/.claude/agents/implementer.md +2 -1
- package/.claude/agents/requirement-analyst.md +1 -0
- package/.claude/agents/reviewer.md +1 -0
- package/.claude/agents/test-reporter.md +1 -0
- package/.claude/settings.json +25 -0
- package/.claude/skills/appium/SKILL.md +1 -1
- package/.claude/skills/appium/templates/README.md +6 -9
- package/.claude/skills/appium/templates/ci/github-actions-android.yml +8 -2
- package/.claude/skills/appium/templates/ci/github-actions-ios.yml +8 -2
- package/.claude/skills/appium/templates/ci/github-actions-windows.yml +9 -2
- package/.claude/skills/appium/templates/project-java/.env.example +4 -0
- package/.claude/skills/appium/templates/project-java/pom.xml +2 -0
- package/.claude/skills/appium/templates/project-java/src/test/java/automation/{framework/Config.java → config/Env.java} +43 -52
- package/.claude/skills/appium/templates/project-java/src/test/java/automation/config/Flags.java +45 -0
- package/.claude/skills/appium/templates/project-java/src/test/java/automation/config/Paths.java +14 -0
- package/.claude/skills/appium/templates/project-java/src/test/java/automation/desc/SignInDesc.java +30 -0
- package/.claude/skills/appium/templates/project-java/src/test/java/automation/{framework → driver}/DriverFactory.java +19 -13
- package/.claude/skills/appium/templates/project-java/src/test/java/automation/{framework → driver}/DriverManager.java +12 -9
- package/.claude/skills/appium/templates/project-java/src/test/java/automation/fixtures/BaseTest.java +75 -0
- package/.claude/skills/appium/templates/project-java/src/test/java/automation/{screens → pageObjects}/BaseScreen.java +12 -12
- package/.claude/skills/appium/templates/project-java/src/test/java/automation/pageObjects/HomeScreen.java +26 -0
- package/.claude/skills/appium/templates/project-java/src/test/java/automation/pageObjects/LoginScreen.java +63 -0
- package/.claude/skills/appium/templates/project-java/src/test/java/automation/pageObjects/ShellScreen.java +26 -0
- package/.claude/skills/appium/templates/project-java/src/test/java/automation/setup/AuthSetup.java +49 -0
- package/.claude/skills/appium/templates/project-java/src/test/java/automation/testData/TestData.java +78 -0
- package/.claude/skills/appium/templates/project-java/src/test/java/automation/tests/ui/SignInTest.java +45 -0
- package/.claude/skills/appium/templates/project-java/src/test/java/automation/tests/unit/UtilsTest.java +34 -0
- package/.claude/skills/appium/templates/project-java/src/test/java/automation/{framework → utils}/AutomationError.java +4 -4
- package/.claude/skills/appium/templates/project-java/src/test/java/automation/utils/Case.java +20 -0
- package/.claude/skills/appium/templates/project-java/src/test/java/automation/utils/CaseTransformer.java +54 -0
- package/.claude/skills/appium/templates/project-java/src/test/java/automation/utils/Dates.java +42 -0
- package/.claude/skills/appium/templates/project-java/src/test/java/automation/utils/Log.java +45 -0
- package/.claude/skills/appium/templates/project-java/src/test/java/automation/utils/MissingSettingError.java +13 -0
- package/.claude/skills/appium/templates/project-java/src/test/java/automation/utils/RandomData.java +41 -0
- package/.claude/skills/appium/templates/project-java/src/test/java/automation/utils/Redact.java +33 -0
- package/.claude/skills/appium/templates/project-java/src/test/java/automation/utils/TestDescription.java +25 -0
- package/.claude/skills/appium/templates/project-java/src/test/resources/testData/testData.properties +7 -0
- package/.claude/skills/appium/templates/project-java/testng.xml +11 -4
- package/.claude/skills/architecture-analysis/SKILL.md +3 -2
- package/.claude/skills/automation-implementation/SKILL.md +8 -5
- package/.claude/skills/automation-implementation/references/patterns.md +46 -24
- package/.claude/skills/automation-review/references/assertion-guard.md +1 -1
- package/.claude/skills/code-review/SKILL.md +5 -2
- package/.claude/skills/code-review/references/pattern-rules.md +12 -7
- package/.claude/skills/documentation/SKILL.md +23 -18
- package/.claude/skills/execution/SKILL.md +7 -3
- package/.claude/skills/httpclient/templates/README.md +6 -7
- package/.claude/skills/httpclient/templates/csharp-nunit/.env.example +4 -0
- package/.claude/skills/httpclient/templates/csharp-nunit/Automation.csproj +7 -3
- package/.claude/skills/httpclient/templates/csharp-nunit/Config/Env.cs +62 -0
- package/.claude/skills/httpclient/templates/csharp-nunit/Config/Flags.cs +35 -0
- package/.claude/skills/httpclient/templates/csharp-nunit/Config/Paths.cs +22 -0
- package/.claude/skills/httpclient/templates/csharp-nunit/Fixtures/BaseTest.cs +22 -0
- package/.claude/skills/httpclient/templates/csharp-nunit/Resources/Desc/ProductsDesc.cs +22 -0
- package/.claude/skills/httpclient/templates/csharp-nunit/Resources/TestData/TestData.cs +61 -0
- package/.claude/skills/httpclient/templates/csharp-nunit/Resources/TestData/testData.json +9 -0
- package/.claude/skills/httpclient/templates/csharp-nunit/Services/ApiClient.cs +48 -0
- package/.claude/skills/httpclient/templates/csharp-nunit/Services/HealthApi.cs +11 -0
- package/.claude/skills/httpclient/templates/csharp-nunit/{Api → Services}/ProductsApi.cs +8 -5
- package/.claude/skills/httpclient/templates/csharp-nunit/Tests/Api/ProductsTests.cs +61 -0
- package/.claude/skills/httpclient/templates/csharp-nunit/Tests/Unit/UtilsTests.cs +40 -0
- package/.claude/skills/httpclient/templates/csharp-nunit/Utils/AutomationError.cs +15 -0
- package/.claude/skills/httpclient/templates/csharp-nunit/Utils/Dates.cs +18 -0
- package/.claude/skills/httpclient/templates/csharp-nunit/Utils/Log.cs +37 -0
- package/.claude/skills/httpclient/templates/csharp-nunit/Utils/RandomData.cs +26 -0
- package/.claude/skills/httpclient/templates/csharp-nunit/Utils/Redact.cs +22 -0
- package/.claude/skills/httpclient/templates/csharp-nunit/Utils/TestDescription.cs +55 -0
- package/.claude/skills/javascript/references/sources.md +1 -1
- package/.claude/skills/k6/SKILL.md +1 -1
- package/.claude/skills/k6/templates/README.md +5 -3
- package/.claude/skills/k6/templates/project/{data/cases.js → resources/desc/products.desc.js} +1 -1
- package/.claude/skills/k6/templates/project/resources/testData/testData.js +32 -0
- package/.claude/skills/k6/templates/project/{lib/config.js → src/config/env.js} +10 -5
- package/.claude/skills/k6/templates/project/{lib → src/services}/products-api.js +7 -5
- package/.claude/skills/k6/templates/project/{load → tests/load}/products.js +8 -8
- package/.claude/skills/karate/templates/README.md +4 -5
- package/.claude/skills/karate/templates/java-junit5/.env.example +2 -0
- package/.claude/skills/karate/templates/java-junit5/pom.xml +4 -0
- package/.claude/skills/karate/templates/java-junit5/src/test/java/{support → config}/EnvSettings.java +1 -1
- package/.claude/skills/karate/templates/java-junit5/src/test/java/karate-config.js +13 -6
- package/.claude/skills/karate/templates/java-junit5/src/test/java/logback-test.xml +1 -1
- package/.claude/skills/karate/templates/java-junit5/src/test/java/{api → tests}/ApiTest.java +7 -4
- package/.claude/skills/karate/templates/java-junit5/src/test/java/{api → tests/api}/health.feature +3 -3
- package/.claude/skills/karate/templates/java-junit5/src/test/java/tests/api/products.feature +29 -0
- package/.claude/skills/karate/templates/java-junit5/src/test/java/{support → utils}/MaskingLogModifier.java +1 -1
- package/.claude/skills/karate/templates/java-junit5/src/test/resources/testData/newProduct.js +7 -0
- package/.claude/skills/karate/templates/java-junit5/src/test/resources/testData/testData.json +6 -0
- package/.claude/skills/newman/templates/README.md +4 -5
- package/.claude/skills/newman/templates/collection/.env.example +2 -0
- package/.claude/skills/newman/templates/collection/collections/api.postman_collection.json +165 -145
- package/.claude/skills/newman/templates/collection/package.json +2 -1
- package/.claude/skills/newman/templates/collection/resources/desc/products.desc.json +53 -0
- package/.claude/skills/newman/templates/collection/resources/testData/testData.json +10 -0
- package/.claude/skills/newman/templates/collection/run.js +41 -31
- package/.claude/skills/newman/templates/collection/src/config/env.js +37 -0
- package/.claude/skills/orion/SKILL.md +19 -12
- package/.claude/skills/orion/references/assess-fix.md +35 -0
- package/.claude/skills/orion/references/batch.md +64 -0
- package/.claude/skills/orion/references/blockers.md +1 -1
- package/.claude/skills/orion/references/capabilities.md +1 -1
- package/.claude/skills/orion/references/conversation.md +65 -20
- package/.claude/skills/orion/references/delivery-formats.md +24 -36
- package/.claude/skills/orion/references/doctor.md +1 -1
- package/.claude/skills/orion/references/hosts.md +1 -0
- package/.claude/skills/orion/references/modes.md +7 -3
- package/.claude/skills/orion/references/plain-language.md +55 -0
- package/.claude/skills/orion/references/project-context-files.md +8 -2
- package/.claude/skills/orion/references/recovery-loop.md +8 -0
- package/.claude/skills/orion/references/setup-card.md +29 -8
- package/.claude/skills/orion/references/status-lines.md +9 -4
- package/.claude/skills/orion/references/task-brief.md +1 -0
- package/.claude/skills/orion/references/work-branch.md +3 -1
- package/.claude/skills/orion/scripts/batch_detect.mjs +98 -0
- package/.claude/skills/orion/scripts/batch_state.mjs +179 -0
- package/.claude/skills/orion/scripts/browser_setup.mjs +41 -21
- package/.claude/skills/orion/scripts/cases_export.py +724 -0
- package/.claude/skills/orion/scripts/codemap.mjs +116 -0
- package/.claude/skills/orion/scripts/done_check.mjs +195 -0
- package/.claude/skills/orion/scripts/env_check.mjs +8 -3
- package/.claude/skills/orion/scripts/env_check.py +12 -5
- package/.claude/skills/orion/scripts/fix_plan.mjs +170 -0
- package/.claude/skills/orion/scripts/graph.mjs +400 -0
- package/.claude/skills/orion/scripts/hooks/lean_guard.mjs +162 -0
- package/.claude/skills/orion/scripts/lib/inside.mjs +31 -0
- package/.claude/skills/orion/scripts/lib/scan.mjs +357 -0
- package/.claude/skills/orion/scripts/lib/table.mjs +116 -0
- package/.claude/skills/orion/scripts/parity_check.mjs +166 -0
- package/.claude/skills/orion/scripts/quiet.mjs +160 -0
- package/.claude/skills/orion/scripts/report_check.mjs +77 -0
- package/.claude/skills/orion/scripts/results_parse.mjs +209 -0
- package/.claude/skills/orion/scripts/reuse_check.mjs +251 -0
- package/.claude/skills/orion/scripts/rules.mjs +92 -0
- package/.claude/skills/orion/scripts/run_state.mjs +238 -0
- package/.claude/skills/orion/scripts/suite_check.mjs +267 -0
- package/.claude/skills/orion/scripts/timing_profile.mjs +128 -0
- package/.claude/skills/orion/scripts/usage_report.mjs +315 -0
- package/.claude/skills/orion/templates/project-context/assessment.md +45 -0
- package/.claude/skills/orion/templates/project-context/defects.md +5 -0
- package/.claude/skills/orion/templates/project-context/report.md +45 -0
- package/.claude/skills/orion/templates/project-context/retry-policy.md +6 -0
- package/.claude/skills/orion/templates/project-context/run.md +4 -1
- package/.claude/skills/orion/templates/project-context/test-case-map.md +5 -0
- package/.claude/skills/orion/templates/project-context/test-design.md +24 -0
- package/.claude/skills/pact/SKILL.md +2 -2
- package/.claude/skills/pact/templates/README.md +4 -2
- package/.claude/skills/pact/templates/project/package.json +2 -2
- package/.claude/skills/pact/templates/project/{data/cases.js → resources/desc/products.desc.js} +3 -3
- package/.claude/skills/pact/templates/project/resources/testData/testData.js +21 -0
- package/.claude/skills/pact/templates/project/src/config/env.js +32 -0
- package/.claude/skills/pact/templates/project/src/{products-client.js → services/products-client.js} +4 -2
- package/.claude/skills/pact/templates/project/tests/contract/products.contract.test.js +46 -0
- package/.claude/skills/pact/templates/project/{verify → tests/verify}/products.verify.js +7 -22
- package/.claude/skills/playwright/SKILL.md +6 -6
- package/.claude/skills/playwright/templates/README.md +29 -10
- package/.claude/skills/playwright/templates/ci/Jenkinsfile +1 -1
- package/.claude/skills/playwright/templates/ci/azure-pipelines.yml +1 -1
- package/.claude/skills/playwright/templates/ci/github-actions-javascript.yml +1 -1
- package/.claude/skills/playwright/templates/ci/github-actions.yml +1 -1
- package/.claude/skills/playwright/templates/ci/gitlab-ci.yml +1 -1
- package/.claude/skills/playwright/templates/dotnet/.env.example +7 -0
- package/.claude/skills/playwright/templates/dotnet/.runsettings +17 -0
- package/.claude/skills/playwright/templates/dotnet/Automation.csproj +8 -0
- package/.claude/skills/playwright/templates/dotnet/Config/Env.cs +89 -0
- package/.claude/skills/playwright/templates/dotnet/Config/Flags.cs +56 -0
- package/.claude/skills/playwright/templates/dotnet/Config/Paths.cs +31 -0
- package/.claude/skills/playwright/templates/dotnet/Fixtures/ApiBaseTest.cs +39 -0
- package/.claude/skills/playwright/templates/dotnet/Fixtures/BaseTest.cs +72 -0
- package/.claude/skills/playwright/templates/dotnet/PageObjects/BasePage.cs +63 -0
- package/.claude/skills/playwright/templates/dotnet/PageObjects/HomePage.cs +21 -0
- package/.claude/skills/playwright/templates/dotnet/PageObjects/LoginPage.cs +54 -0
- package/.claude/skills/playwright/templates/dotnet/PageObjects/ShellPage.cs +29 -0
- package/.claude/skills/playwright/templates/dotnet/Resources/Desc/SignInDesc.cs +23 -0
- package/.claude/skills/playwright/templates/dotnet/Resources/TestData/TestData.cs +74 -0
- package/.claude/skills/playwright/templates/dotnet/Resources/TestData/testData.json +19 -0
- package/.claude/skills/playwright/templates/dotnet/Services/ApiClient.cs +51 -0
- package/.claude/skills/playwright/templates/dotnet/Setup/AuthSetup.cs +63 -0
- package/.claude/skills/playwright/templates/dotnet/Tests/Api/SessionTests.cs +18 -0
- package/.claude/skills/playwright/templates/dotnet/Tests/Ui/SignInTests.cs +48 -0
- package/.claude/skills/playwright/templates/dotnet/Tests/Unit/UtilsTests.cs +40 -0
- package/.claude/skills/playwright/templates/dotnet/Utils/AutomationError.cs +15 -0
- package/.claude/skills/playwright/templates/dotnet/Utils/Dates.cs +18 -0
- package/.claude/skills/playwright/templates/dotnet/Utils/Log.cs +37 -0
- package/.claude/skills/playwright/templates/dotnet/Utils/RandomData.cs +26 -0
- package/.claude/skills/playwright/templates/dotnet/Utils/Redact.cs +22 -0
- package/.claude/skills/playwright/templates/dotnet/Utils/TestDescription.cs +55 -0
- package/.claude/skills/playwright/templates/dotnet/gitignore +6 -1
- package/.claude/skills/playwright/templates/javascript/.env.example +8 -0
- package/.claude/skills/playwright/templates/javascript/fixtures/index.js +85 -0
- package/.claude/skills/playwright/templates/javascript/fixtures/session.js +82 -0
- package/.claude/skills/playwright/templates/javascript/gitignore +7 -0
- package/.claude/skills/playwright/templates/javascript/jsconfig.json +12 -0
- package/.claude/skills/playwright/templates/javascript/package.json +7 -3
- package/.claude/skills/playwright/templates/javascript/pageObjects/basePage.js +62 -0
- package/.claude/skills/playwright/templates/javascript/pageObjects/homePage.js +19 -0
- package/.claude/skills/playwright/templates/javascript/pageObjects/loginPage.js +44 -0
- package/.claude/skills/playwright/templates/javascript/pageObjects/shellPage.js +26 -0
- package/.claude/skills/playwright/templates/javascript/playwright.config.js +45 -24
- package/.claude/skills/playwright/templates/javascript/reporters/summaryReporter.js +233 -0
- package/.claude/skills/playwright/templates/javascript/resources/desc/signIn.desc.js +33 -0
- package/.claude/skills/playwright/templates/javascript/resources/testData/testData.js +45 -0
- package/.claude/skills/playwright/templates/javascript/setup/auth.setup.js +17 -0
- package/.claude/skills/playwright/templates/javascript/setup/auth.teardown.js +16 -0
- package/.claude/skills/playwright/templates/javascript/src/config/env.js +107 -0
- package/.claude/skills/playwright/templates/javascript/src/config/flags.js +70 -0
- package/.claude/skills/playwright/templates/javascript/src/config/loadEnv.js +21 -0
- package/.claude/skills/playwright/templates/javascript/src/config/paths.js +22 -0
- package/.claude/skills/playwright/templates/javascript/src/services/apiClient.js +68 -0
- package/.claude/skills/playwright/templates/javascript/tests/api/session.spec.js +15 -0
- package/.claude/skills/playwright/templates/javascript/tests/ui/signIn.spec.js +35 -0
- package/.claude/skills/playwright/templates/javascript/tests/unit/summaryReporter.test.js +34 -0
- package/.claude/skills/playwright/templates/javascript/tests/unit/utils.test.js +31 -0
- package/.claude/skills/playwright/templates/javascript/utils/date.js +28 -0
- package/.claude/skills/playwright/templates/javascript/{src → utils}/errors.js +1 -0
- package/.claude/skills/playwright/templates/javascript/utils/formFill.js +29 -0
- package/.claude/skills/playwright/templates/javascript/utils/logger.js +33 -0
- package/.claude/skills/playwright/templates/javascript/utils/random.js +37 -0
- package/.claude/skills/playwright/templates/javascript/utils/redact.js +35 -0
- package/.claude/skills/playwright/templates/javascript/utils/titles.js +38 -0
- package/.claude/skills/playwright/templates/project/.env.example +8 -0
- package/.claude/skills/playwright/templates/project/fixtures/index.ts +86 -0
- package/.claude/skills/playwright/templates/project/fixtures/session.ts +78 -0
- package/.claude/skills/playwright/templates/project/gitignore +9 -2
- package/.claude/skills/playwright/templates/project/package.json +8 -6
- package/.claude/skills/playwright/templates/project/pageObjects/basePage.ts +57 -0
- package/.claude/skills/playwright/templates/project/pageObjects/homePage.ts +20 -0
- package/.claude/skills/playwright/templates/project/pageObjects/loginPage.ts +47 -0
- package/.claude/skills/playwright/templates/project/pageObjects/shellPage.ts +22 -0
- package/.claude/skills/playwright/templates/project/playwright.config.ts +49 -23
- package/.claude/skills/playwright/templates/project/reporters/summaryReporter.ts +241 -0
- package/.claude/skills/playwright/templates/project/resources/desc/signIn.desc.ts +32 -0
- package/.claude/skills/playwright/templates/project/resources/testData/testData.ts +42 -0
- package/.claude/skills/playwright/templates/project/setup/auth.setup.ts +16 -0
- package/.claude/skills/playwright/templates/project/setup/auth.teardown.ts +15 -0
- package/.claude/skills/playwright/templates/project/src/config/env.ts +109 -0
- package/.claude/skills/playwright/templates/project/src/config/flags.ts +70 -0
- package/.claude/skills/playwright/templates/project/src/config/loadEnv.ts +17 -0
- package/.claude/skills/playwright/templates/project/src/config/paths.ts +19 -0
- package/.claude/skills/playwright/templates/project/src/services/apiClient.ts +70 -0
- package/.claude/skills/playwright/templates/project/tests/api/session.spec.ts +14 -0
- package/.claude/skills/playwright/templates/project/tests/ui/signIn.spec.ts +34 -0
- package/.claude/skills/playwright/templates/project/tests/unit/summaryReporter.test.ts +33 -0
- package/.claude/skills/playwright/templates/project/tests/unit/utils.test.ts +30 -0
- package/.claude/skills/playwright/templates/project/tsconfig.json +3 -8
- package/.claude/skills/playwright/templates/project/utils/date.ts +25 -0
- package/.claude/skills/playwright/templates/project/utils/formFill.ts +27 -0
- package/.claude/skills/playwright/templates/project/utils/logger.ts +32 -0
- package/.claude/skills/playwright/templates/project/utils/random.ts +34 -0
- package/.claude/skills/playwright/templates/project/utils/redact.ts +32 -0
- package/.claude/skills/playwright/templates/project/utils/titles.ts +42 -0
- package/.claude/skills/playwright/templates/python/.env.example +8 -0
- package/.claude/skills/playwright/templates/python/conftest.py +91 -16
- package/.claude/skills/playwright/templates/python/gitignore +5 -0
- package/.claude/skills/playwright/templates/python/page_objects/__init__.py +1 -0
- package/.claude/skills/playwright/templates/python/page_objects/base_page.py +57 -0
- package/.claude/skills/playwright/templates/python/page_objects/home_page.py +22 -0
- package/.claude/skills/playwright/templates/python/page_objects/login_page.py +42 -0
- package/.claude/skills/playwright/templates/python/page_objects/shell_page.py +21 -0
- package/.claude/skills/playwright/templates/python/pytest.ini +5 -2
- package/.claude/skills/playwright/templates/python/requirements.txt +1 -0
- package/.claude/skills/playwright/templates/python/resources/__init__.py +1 -0
- package/.claude/skills/playwright/templates/python/resources/desc/__init__.py +1 -0
- package/.claude/skills/playwright/templates/python/resources/desc/sign_in_desc.py +27 -0
- package/.claude/skills/playwright/templates/python/resources/test_data/__init__.py +1 -0
- package/.claude/skills/playwright/templates/python/resources/test_data/test_data.py +41 -0
- package/.claude/skills/playwright/templates/python/setup/__init__.py +1 -0
- package/.claude/skills/playwright/templates/python/setup/auth.py +53 -0
- package/.claude/skills/playwright/templates/python/src/__init__.py +1 -0
- package/.claude/skills/playwright/templates/python/src/config/__init__.py +1 -0
- package/.claude/skills/playwright/templates/python/src/config/env.py +109 -0
- package/.claude/skills/playwright/templates/python/src/config/flags.py +63 -0
- package/.claude/skills/playwright/templates/python/src/config/load_env.py +16 -0
- package/.claude/skills/playwright/templates/python/src/config/paths.py +25 -0
- package/.claude/skills/playwright/templates/python/src/services/__init__.py +1 -0
- package/.claude/skills/playwright/templates/python/src/services/api_client.py +60 -0
- package/.claude/skills/playwright/templates/python/tests/api/test_session.py +14 -0
- package/.claude/skills/playwright/templates/python/tests/ui/test_sign_in.py +36 -0
- package/.claude/skills/playwright/templates/python/tests/unit/test_utils.py +32 -0
- package/.claude/skills/playwright/templates/python/utils/__init__.py +1 -0
- package/.claude/skills/playwright/templates/python/utils/dates.py +23 -0
- package/.claude/skills/playwright/templates/python/{framework → utils}/errors.py +3 -2
- package/.claude/skills/playwright/templates/python/utils/form_fill.py +26 -0
- package/.claude/skills/playwright/templates/python/utils/logger.py +40 -0
- package/.claude/skills/playwright/templates/python/utils/markers.py +6 -0
- package/.claude/skills/playwright/templates/python/utils/random_data.py +35 -0
- package/.claude/skills/playwright/templates/python/utils/redact.py +30 -0
- package/.claude/skills/playwright/templates/python/utils/titles.py +53 -0
- package/.claude/skills/quality-checks/SKILL.md +11 -11
- package/.claude/skills/quality-checks/templates/README.md +14 -12
- package/.claude/skills/quality-checks/templates/playwright-js/pageObjects/scannedPage.js +21 -0
- package/.claude/skills/quality-checks/templates/playwright-js/resources/desc/quality.desc.js +63 -0
- package/.claude/skills/quality-checks/templates/playwright-js/resources/testData/qualityData.js +32 -0
- package/.claude/skills/quality-checks/templates/playwright-js/src/checks/accessibility.js +50 -0
- package/.claude/skills/quality-checks/templates/playwright-js/src/checks/pageHealth.js +38 -0
- package/.claude/skills/quality-checks/templates/playwright-js/src/checks/performance.js +21 -0
- package/.claude/skills/quality-checks/templates/playwright-js/src/services/graphqlClient.js +28 -0
- package/.claude/skills/quality-checks/templates/playwright-js/tests/api/graphql.spec.js +23 -0
- package/.claude/skills/quality-checks/templates/playwright-js/tests/ui/quality.spec.js +50 -0
- package/.claude/skills/quality-checks/templates/playwright-ts/pageObjects/scannedPage.ts +20 -0
- package/.claude/skills/quality-checks/templates/playwright-ts/resources/desc/quality.desc.ts +59 -0
- package/.claude/skills/quality-checks/templates/playwright-ts/{src/data/quality.data.ts → resources/testData/qualityData.ts} +3 -2
- package/.claude/skills/quality-checks/templates/playwright-ts/tests/api/graphql.spec.ts +22 -0
- package/.claude/skills/quality-checks/templates/playwright-ts/tests/ui/quality.spec.ts +49 -0
- package/.claude/skills/requests/templates/README.md +6 -7
- package/.claude/skills/requests/templates/python-pytest/.env.example +4 -0
- package/.claude/skills/requests/templates/python-pytest/conftest.py +24 -9
- package/.claude/skills/requests/templates/python-pytest/pytest.ini +6 -3
- package/.claude/skills/requests/templates/python-pytest/requirements.txt +1 -0
- package/.claude/skills/requests/templates/python-pytest/resources/__init__.py +1 -0
- package/.claude/skills/requests/templates/python-pytest/resources/desc/__init__.py +1 -0
- package/.claude/skills/requests/templates/python-pytest/resources/desc/products_desc.py +27 -0
- package/.claude/skills/requests/templates/python-pytest/resources/test_data/__init__.py +1 -0
- package/.claude/skills/requests/templates/python-pytest/resources/test_data/test_data.py +27 -0
- package/.claude/skills/requests/templates/python-pytest/src/__init__.py +1 -0
- package/.claude/skills/requests/templates/python-pytest/src/config/__init__.py +1 -0
- package/.claude/skills/requests/templates/python-pytest/src/config/env.py +39 -0
- package/.claude/skills/requests/templates/python-pytest/src/config/flags.py +35 -0
- package/.claude/skills/requests/templates/python-pytest/src/config/load_env.py +16 -0
- package/.claude/skills/requests/templates/python-pytest/src/config/paths.py +16 -0
- package/.claude/skills/requests/templates/python-pytest/src/services/__init__.py +1 -0
- package/.claude/skills/requests/templates/python-pytest/{api/client.py → src/services/api_client.py} +19 -10
- package/.claude/skills/requests/templates/python-pytest/{api → src/services}/products_api.py +3 -9
- package/.claude/skills/requests/templates/python-pytest/tests/api/test_products.py +35 -0
- package/.claude/skills/requests/templates/python-pytest/tests/unit/test_utils.py +32 -0
- package/.claude/skills/requests/templates/python-pytest/utils/__init__.py +1 -0
- package/.claude/skills/requests/templates/python-pytest/utils/dates.py +23 -0
- package/.claude/skills/{selenium/templates/python-pytest/framework → requests/templates/python-pytest/utils}/errors.py +4 -3
- package/.claude/skills/requests/templates/python-pytest/utils/logger.py +40 -0
- package/.claude/skills/requests/templates/python-pytest/utils/random_data.py +35 -0
- package/.claude/skills/requests/templates/python-pytest/utils/redact.py +30 -0
- package/.claude/skills/requests/templates/python-pytest/utils/titles.py +53 -0
- package/.claude/skills/requirement-analysis/SKILL.md +1 -1
- package/.claude/skills/rest-assured/SKILL.md +1 -1
- package/.claude/skills/rest-assured/templates/README.md +6 -7
- package/.claude/skills/rest-assured/templates/ci/github-actions.yml +5 -2
- package/.claude/skills/rest-assured/templates/java-testng/.env.example +3 -0
- package/.claude/skills/rest-assured/templates/java-testng/pom.xml +7 -0
- package/.claude/skills/rest-assured/templates/java-testng/src/test/java/automation/{api/ApiConfig.java → config/Env.java} +35 -22
- package/.claude/skills/rest-assured/templates/java-testng/src/test/java/automation/config/Flags.java +17 -0
- package/.claude/skills/rest-assured/templates/java-testng/src/test/java/automation/config/Paths.java +14 -0
- package/.claude/skills/rest-assured/templates/java-testng/src/test/java/automation/desc/ProductsDesc.java +26 -0
- package/.claude/skills/rest-assured/templates/java-testng/src/test/java/automation/fixtures/BaseTest.java +29 -0
- package/.claude/skills/rest-assured/templates/java-testng/src/test/java/automation/services/ApiSpec.java +31 -0
- package/.claude/skills/rest-assured/templates/java-testng/src/test/java/automation/services/HealthApi.java +17 -0
- package/.claude/skills/rest-assured/templates/java-testng/src/test/java/automation/{api → services}/ProductsApi.java +19 -14
- package/.claude/skills/rest-assured/templates/java-testng/src/test/java/automation/{data → testData}/ProductBuilder.java +4 -8
- package/.claude/skills/rest-assured/templates/java-testng/src/test/java/automation/testData/TestData.java +64 -0
- package/.claude/skills/rest-assured/templates/java-testng/src/test/java/automation/tests/api/ProductsTest.java +49 -0
- package/.claude/skills/rest-assured/templates/java-testng/src/test/java/automation/tests/unit/UtilsTest.java +34 -0
- package/.claude/skills/{selenium/templates/java-testng/src/test/java/automation/framework → rest-assured/templates/java-testng/src/test/java/automation/utils}/AutomationError.java +4 -4
- package/.claude/skills/rest-assured/templates/java-testng/src/test/java/automation/utils/Case.java +20 -0
- package/.claude/skills/rest-assured/templates/java-testng/src/test/java/automation/utils/CaseTransformer.java +54 -0
- package/.claude/skills/rest-assured/templates/java-testng/src/test/java/automation/utils/Dates.java +42 -0
- package/.claude/skills/rest-assured/templates/java-testng/src/test/java/automation/utils/Log.java +45 -0
- package/.claude/skills/rest-assured/templates/java-testng/src/test/java/automation/utils/MissingSettingError.java +13 -0
- package/.claude/skills/rest-assured/templates/java-testng/src/test/java/automation/utils/RandomData.java +41 -0
- package/.claude/skills/rest-assured/templates/java-testng/src/test/java/automation/utils/Redact.java +33 -0
- package/.claude/skills/rest-assured/templates/java-testng/src/test/java/automation/utils/TestDescription.java +25 -0
- package/.claude/skills/rest-assured/templates/java-testng/src/test/resources/testData/testData.properties +14 -0
- package/.claude/skills/rest-assured/templates/java-testng/testng.xml +14 -0
- package/.claude/skills/selenium/SKILL.md +1 -1
- package/.claude/skills/selenium/templates/README.md +25 -13
- package/.claude/skills/selenium/templates/ci/github-actions-java.yml +5 -2
- package/.claude/skills/selenium/templates/csharp-nunit/.env.example +15 -0
- package/.claude/skills/selenium/templates/csharp-nunit/Automation.csproj +7 -0
- package/.claude/skills/selenium/templates/csharp-nunit/{Framework/Config.cs → Config/Env.cs} +33 -34
- package/.claude/skills/selenium/templates/csharp-nunit/Config/Flags.cs +39 -0
- package/.claude/skills/selenium/templates/csharp-nunit/Config/Paths.cs +31 -0
- package/.claude/skills/selenium/templates/csharp-nunit/{Framework → Driver}/DriverFactory.cs +16 -13
- package/.claude/skills/selenium/templates/csharp-nunit/Driver/DriverManager.cs +27 -0
- package/.claude/skills/selenium/templates/csharp-nunit/Fixtures/BaseTest.cs +56 -0
- package/.claude/skills/selenium/templates/csharp-nunit/{Pages → PageObjects}/BasePage.cs +44 -14
- package/.claude/skills/selenium/templates/csharp-nunit/PageObjects/HomePage.cs +21 -0
- package/.claude/skills/selenium/templates/csharp-nunit/PageObjects/LoginPage.cs +53 -0
- package/.claude/skills/selenium/templates/csharp-nunit/PageObjects/ShellPage.cs +22 -0
- package/.claude/skills/selenium/templates/csharp-nunit/Resources/Desc/SignInDesc.cs +23 -0
- package/.claude/skills/selenium/templates/csharp-nunit/Resources/TestData/TestData.cs +74 -0
- package/.claude/skills/selenium/templates/csharp-nunit/Resources/TestData/testData.json +14 -0
- package/.claude/skills/selenium/templates/csharp-nunit/Services/ApiClient.cs +71 -0
- package/.claude/skills/selenium/templates/csharp-nunit/Setup/AuthSetup.cs +104 -0
- package/.claude/skills/selenium/templates/csharp-nunit/Tests/Api/SessionTests.cs +23 -0
- package/.claude/skills/selenium/templates/csharp-nunit/Tests/Ui/SignInTests.cs +42 -0
- package/.claude/skills/selenium/templates/csharp-nunit/Tests/Unit/UtilsTests.cs +40 -0
- package/.claude/skills/selenium/templates/csharp-nunit/Utils/AutomationError.cs +15 -0
- package/.claude/skills/selenium/templates/csharp-nunit/Utils/Dates.cs +18 -0
- package/.claude/skills/selenium/templates/csharp-nunit/Utils/FormFill.cs +20 -0
- package/.claude/skills/selenium/templates/csharp-nunit/Utils/Log.cs +37 -0
- package/.claude/skills/selenium/templates/csharp-nunit/Utils/RandomData.cs +26 -0
- package/.claude/skills/selenium/templates/csharp-nunit/Utils/Redact.cs +22 -0
- package/.claude/skills/selenium/templates/csharp-nunit/Utils/TestDescription.cs +55 -0
- package/.claude/skills/selenium/templates/csharp-nunit/gitignore +6 -2
- package/.claude/skills/selenium/templates/java-testng/.env.example +12 -0
- package/.claude/skills/selenium/templates/java-testng/gitignore +5 -2
- package/.claude/skills/selenium/templates/java-testng/pom.xml +2 -0
- package/.claude/skills/selenium/templates/java-testng/src/test/java/automation/{framework/Config.java → config/Env.java} +45 -55
- package/.claude/skills/selenium/templates/java-testng/src/test/java/automation/config/Flags.java +50 -0
- package/.claude/skills/selenium/templates/java-testng/src/test/java/automation/config/Paths.java +20 -0
- package/.claude/skills/selenium/templates/java-testng/src/test/java/automation/desc/SignInDesc.java +30 -0
- package/.claude/skills/selenium/templates/java-testng/src/test/java/automation/{framework → driver}/DriverFactory.java +15 -12
- package/.claude/skills/selenium/templates/java-testng/src/test/java/automation/{framework → driver}/DriverManager.java +4 -7
- package/.claude/skills/selenium/templates/java-testng/src/test/java/automation/fixtures/BaseTest.java +87 -0
- package/.claude/skills/selenium/templates/java-testng/src/test/java/automation/{pages → pageObjects}/BasePage.java +41 -17
- package/.claude/skills/selenium/templates/java-testng/src/test/java/automation/pageObjects/HomePage.java +32 -0
- package/.claude/skills/selenium/templates/java-testng/src/test/java/automation/pageObjects/LoginPage.java +69 -0
- package/.claude/skills/selenium/templates/java-testng/src/test/java/automation/pageObjects/ShellPage.java +34 -0
- package/.claude/skills/selenium/templates/java-testng/src/test/java/automation/services/ApiClient.java +93 -0
- package/.claude/skills/selenium/templates/java-testng/src/test/java/automation/setup/AuthSetup.java +125 -0
- package/.claude/skills/selenium/templates/java-testng/src/test/java/automation/testData/TestData.java +88 -0
- package/.claude/skills/selenium/templates/java-testng/src/test/java/automation/tests/api/SessionTest.java +23 -0
- package/.claude/skills/selenium/templates/java-testng/src/test/java/automation/tests/ui/SignInTest.java +46 -0
- package/.claude/skills/selenium/templates/java-testng/src/test/java/automation/tests/unit/UtilsTest.java +34 -0
- package/.claude/skills/selenium/templates/java-testng/src/test/java/automation/utils/AutomationError.java +18 -0
- package/.claude/skills/selenium/templates/java-testng/src/test/java/automation/utils/Case.java +20 -0
- package/.claude/skills/selenium/templates/java-testng/src/test/java/automation/utils/CaseTransformer.java +54 -0
- package/.claude/skills/selenium/templates/java-testng/src/test/java/automation/utils/Dates.java +42 -0
- package/.claude/skills/selenium/templates/java-testng/src/test/java/automation/utils/FormFill.java +25 -0
- package/.claude/skills/selenium/templates/java-testng/src/test/java/automation/utils/Log.java +45 -0
- package/.claude/skills/selenium/templates/java-testng/src/test/java/automation/utils/MissingSettingError.java +13 -0
- package/.claude/skills/selenium/templates/java-testng/src/test/java/automation/utils/RandomData.java +41 -0
- package/.claude/skills/selenium/templates/java-testng/src/test/java/automation/utils/Redact.java +33 -0
- package/.claude/skills/selenium/templates/java-testng/src/test/java/automation/utils/TestDescription.java +25 -0
- package/.claude/skills/selenium/templates/java-testng/src/test/resources/testData/testData.properties +11 -0
- package/.claude/skills/selenium/templates/java-testng/testng.xml +15 -5
- package/.claude/skills/selenium/templates/python-pytest/.env.example +12 -0
- package/.claude/skills/selenium/templates/python-pytest/conftest.py +63 -12
- package/.claude/skills/selenium/templates/python-pytest/gitignore +7 -2
- package/.claude/skills/selenium/templates/python-pytest/page_objects/__init__.py +1 -0
- package/.claude/skills/selenium/templates/python-pytest/{pages → page_objects}/base_page.py +20 -20
- package/.claude/skills/selenium/templates/python-pytest/page_objects/home_page.py +17 -0
- package/.claude/skills/selenium/templates/python-pytest/{pages → page_objects}/login_page.py +12 -14
- package/.claude/skills/selenium/templates/python-pytest/page_objects/shell_page.py +16 -0
- package/.claude/skills/selenium/templates/python-pytest/pytest.ini +6 -2
- package/.claude/skills/selenium/templates/python-pytest/requirements.txt +1 -0
- package/.claude/skills/selenium/templates/python-pytest/resources/__init__.py +1 -0
- package/.claude/skills/selenium/templates/python-pytest/resources/desc/__init__.py +1 -0
- package/.claude/skills/selenium/templates/python-pytest/resources/desc/sign_in_desc.py +27 -0
- package/.claude/skills/selenium/templates/python-pytest/resources/test_data/__init__.py +1 -0
- package/.claude/skills/selenium/templates/python-pytest/resources/test_data/test_data.py +25 -0
- package/.claude/skills/selenium/templates/python-pytest/setup/__init__.py +1 -0
- package/.claude/skills/selenium/templates/python-pytest/setup/auth.py +60 -0
- package/.claude/skills/selenium/templates/python-pytest/src/__init__.py +1 -0
- package/.claude/skills/selenium/templates/python-pytest/src/config/__init__.py +1 -0
- package/.claude/skills/selenium/templates/python-pytest/src/config/env.py +68 -0
- package/.claude/skills/selenium/templates/python-pytest/src/config/flags.py +40 -0
- package/.claude/skills/selenium/templates/python-pytest/src/config/load_env.py +16 -0
- package/.claude/skills/selenium/templates/python-pytest/src/config/paths.py +25 -0
- package/.claude/skills/selenium/templates/python-pytest/src/driver/__init__.py +1 -0
- package/.claude/skills/selenium/templates/python-pytest/{framework → src/driver}/driver_factory.py +11 -18
- package/.claude/skills/selenium/templates/python-pytest/{framework → src/driver}/driver_manager.py +3 -3
- package/.claude/skills/selenium/templates/python-pytest/src/services/__init__.py +1 -0
- package/.claude/skills/selenium/templates/python-pytest/src/services/api_client.py +89 -0
- package/.claude/skills/selenium/templates/python-pytest/tests/api/test_session.py +11 -0
- package/.claude/skills/selenium/templates/python-pytest/tests/ui/test_sign_in.py +34 -0
- package/.claude/skills/selenium/templates/python-pytest/tests/unit/test_utils.py +32 -0
- package/.claude/skills/selenium/templates/python-pytest/utils/__init__.py +1 -0
- package/.claude/skills/selenium/templates/python-pytest/utils/dates.py +23 -0
- package/.claude/skills/selenium/templates/python-pytest/utils/errors.py +28 -0
- package/.claude/skills/selenium/templates/python-pytest/utils/form_fill.py +29 -0
- package/.claude/skills/selenium/templates/python-pytest/utils/logger.py +40 -0
- package/.claude/skills/selenium/templates/python-pytest/utils/markers.py +6 -0
- package/.claude/skills/selenium/templates/python-pytest/utils/random_data.py +35 -0
- package/.claude/skills/selenium/templates/python-pytest/utils/redact.py +30 -0
- package/.claude/skills/selenium/templates/python-pytest/utils/titles.py +53 -0
- package/.claude/skills/self-healing/SKILL.md +2 -2
- package/.claude/skills/test-design/SKILL.md +1 -1
- package/.claude/skills/test-reporting/references/tool-mapping.md +13 -9
- package/.claude/skills/ui-observation/SKILL.md +8 -6
- package/.claude/skills/ui-observation/references/login-methods.md +1 -1
- package/.claude-plugin/plugin.json +15 -2
- package/.codex/agents/automation-strategist.toml +1 -0
- package/.codex/agents/change-agent.toml +1 -0
- package/.codex/agents/codebase-analyst.toml +1 -0
- package/.codex/agents/environment-discovery.toml +1 -0
- package/.codex/agents/evidence-validator.toml +1 -0
- package/.codex/agents/executor.toml +1 -0
- package/.codex/agents/failure-analyst.toml +1 -0
- package/.codex/agents/implementer.toml +2 -1
- package/.codex/agents/requirement-analyst.toml +1 -0
- package/.codex/agents/reviewer.toml +1 -0
- package/.codex/agents/test-reporter.toml +1 -0
- package/.codex/hooks.json +15 -0
- package/.cursor/commands/orion.md +1 -1
- package/.cursor/hooks.json +10 -0
- package/.devin/hooks.v1.json +13 -0
- package/.gemini/agents/automation-strategist.md +1 -0
- package/.gemini/agents/change-agent.md +1 -0
- package/.gemini/agents/codebase-analyst.md +1 -0
- package/.gemini/agents/environment-discovery.md +1 -0
- package/.gemini/agents/evidence-validator.md +1 -0
- package/.gemini/agents/executor.md +1 -0
- package/.gemini/agents/failure-analyst.md +1 -0
- package/.gemini/agents/implementer.md +2 -1
- package/.gemini/agents/requirement-analyst.md +1 -0
- package/.gemini/agents/reviewer.md +1 -0
- package/.gemini/agents/test-reporter.md +1 -0
- package/.gemini/commands/orion.toml +2 -2
- package/.github/hooks/orion-lean.json +13 -0
- package/.github/prompts/orion.prompt.md +2 -2
- package/.windsurf/workflows/orion.md +2 -2
- package/AGENTS.md +6 -6
- package/README.md +55 -140
- package/assets/architecture.svg +104 -0
- package/assets/run-flow.svg +1 -1
- package/bin/orion.mjs +6 -6
- package/hosts/gemini-extension/gemini-extension.json +1 -1
- package/hosts/gemini-extension/hooks/hooks.json +16 -0
- package/hosts/gemini-extension/policies/platform.toml +5 -0
- package/package.json +6 -1
- package/.claude/skills/appium/templates/project-java/src/test/java/automation/data/Cases.java +0 -37
- package/.claude/skills/appium/templates/project-java/src/test/java/automation/data/SignInData.java +0 -25
- package/.claude/skills/appium/templates/project-java/src/test/java/automation/flows/SignInFlow.java +0 -34
- package/.claude/skills/appium/templates/project-java/src/test/java/automation/framework/Account.java +0 -19
- package/.claude/skills/appium/templates/project-java/src/test/java/automation/screens/HomeScreen.java +0 -36
- package/.claude/skills/appium/templates/project-java/src/test/java/automation/screens/LoginScreen.java +0 -57
- package/.claude/skills/appium/templates/project-java/src/test/java/automation/tests/BaseTest.java +0 -33
- package/.claude/skills/appium/templates/project-java/src/test/java/automation/tests/SmokeTest.java +0 -17
- package/.claude/skills/httpclient/templates/csharp-nunit/Api/ApiClient.cs +0 -61
- package/.claude/skills/httpclient/templates/csharp-nunit/Api/ApiConfig.cs +0 -61
- package/.claude/skills/httpclient/templates/csharp-nunit/Api/ApiError.cs +0 -17
- package/.claude/skills/httpclient/templates/csharp-nunit/Data/Cases.cs +0 -41
- package/.claude/skills/httpclient/templates/csharp-nunit/Data/HealthData.cs +0 -11
- package/.claude/skills/httpclient/templates/csharp-nunit/Data/ProductBuilder.cs +0 -16
- package/.claude/skills/httpclient/templates/csharp-nunit/Data/ProductsData.cs +0 -17
- package/.claude/skills/httpclient/templates/csharp-nunit/Tests/HealthTests.cs +0 -18
- package/.claude/skills/httpclient/templates/csharp-nunit/Tests/ProductsTests.cs +0 -48
- package/.claude/skills/k6/templates/project/data/builders.js +0 -8
- package/.claude/skills/karate/templates/java-junit5/src/test/java/api/products.feature +0 -33
- package/.claude/skills/pact/templates/project/test/contract/products.contract.test.js +0 -45
- package/.claude/skills/playwright/templates/dotnet/Components/AccountMenu.cs +0 -23
- package/.claude/skills/playwright/templates/dotnet/Data/Cases.cs +0 -43
- package/.claude/skills/playwright/templates/dotnet/Data/SignInData.cs +0 -24
- package/.claude/skills/playwright/templates/dotnet/Flows/SignInFlow.cs +0 -51
- package/.claude/skills/playwright/templates/dotnet/Framework/AutomationError.cs +0 -17
- package/.claude/skills/playwright/templates/dotnet/Framework/Config.cs +0 -91
- package/.claude/skills/playwright/templates/dotnet/Pages/BasePage.cs +0 -57
- package/.claude/skills/playwright/templates/dotnet/Pages/HomePage.cs +0 -26
- package/.claude/skills/playwright/templates/dotnet/Pages/LoginPage.cs +0 -45
- package/.claude/skills/playwright/templates/dotnet/Tests/SmokeTests.cs +0 -47
- package/.claude/skills/playwright/templates/javascript/src/components/account-menu.component.js +0 -30
- package/.claude/skills/playwright/templates/javascript/src/config.js +0 -53
- package/.claude/skills/playwright/templates/javascript/src/data/accounts.js +0 -23
- package/.claude/skills/playwright/templates/javascript/src/data/cases.js +0 -49
- package/.claude/skills/playwright/templates/javascript/src/data/sign-in.data.js +0 -12
- package/.claude/skills/playwright/templates/javascript/src/flows/sign-in.flow.js +0 -53
- package/.claude/skills/playwright/templates/javascript/src/pages/base.page.js +0 -59
- package/.claude/skills/playwright/templates/javascript/src/pages/home.page.js +0 -31
- package/.claude/skills/playwright/templates/javascript/src/pages/login.page.js +0 -56
- package/.claude/skills/playwright/templates/javascript/tests/fixtures.js +0 -20
- package/.claude/skills/playwright/templates/javascript/tests/smoke.spec.js +0 -22
- package/.claude/skills/playwright/templates/project/src/components/account-menu.component.ts +0 -27
- package/.claude/skills/playwright/templates/project/src/config.ts +0 -56
- package/.claude/skills/playwright/templates/project/src/data/accounts.ts +0 -21
- package/.claude/skills/playwright/templates/project/src/data/cases.ts +0 -55
- package/.claude/skills/playwright/templates/project/src/data/sign-in.data.ts +0 -10
- package/.claude/skills/playwright/templates/project/src/flows/sign-in.flow.ts +0 -51
- package/.claude/skills/playwright/templates/project/src/pages/base.page.ts +0 -52
- package/.claude/skills/playwright/templates/project/src/pages/home.page.ts +0 -30
- package/.claude/skills/playwright/templates/project/src/pages/login.page.ts +0 -53
- package/.claude/skills/playwright/templates/project/tests/fixtures.ts +0 -25
- package/.claude/skills/playwright/templates/project/tests/smoke.spec.ts +0 -22
- package/.claude/skills/playwright/templates/python/components/__init__.py +0 -1
- package/.claude/skills/playwright/templates/python/components/account_menu.py +0 -22
- package/.claude/skills/playwright/templates/python/data/accounts.py +0 -14
- package/.claude/skills/playwright/templates/python/data/cases.py +0 -33
- package/.claude/skills/playwright/templates/python/data/sign_in_data.py +0 -9
- package/.claude/skills/playwright/templates/python/flows/sign_in.py +0 -63
- package/.claude/skills/playwright/templates/python/framework/config.py +0 -86
- package/.claude/skills/playwright/templates/python/pages/base_page.py +0 -51
- package/.claude/skills/playwright/templates/python/pages/home_page.py +0 -21
- package/.claude/skills/playwright/templates/python/pages/login_page.py +0 -40
- package/.claude/skills/playwright/templates/python/tests/test_smoke.py +0 -26
- package/.claude/skills/quality-checks/templates/playwright-ts/src/pages/scanned.page.ts +0 -16
- package/.claude/skills/quality-checks/templates/playwright-ts/tests/quality.spec.ts +0 -58
- package/.claude/skills/requests/templates/python-pytest/api/config.py +0 -43
- package/.claude/skills/requests/templates/python-pytest/api/errors.py +0 -15
- package/.claude/skills/requests/templates/python-pytest/data/builders.py +0 -16
- package/.claude/skills/requests/templates/python-pytest/data/cases.py +0 -30
- package/.claude/skills/requests/templates/python-pytest/data/health_data.py +0 -6
- package/.claude/skills/requests/templates/python-pytest/data/products_data.py +0 -10
- package/.claude/skills/requests/templates/python-pytest/tests/test_health.py +0 -12
- package/.claude/skills/requests/templates/python-pytest/tests/test_products.py +0 -25
- package/.claude/skills/rest-assured/templates/java-testng/src/test/java/automation/api/ApiError.java +0 -18
- package/.claude/skills/rest-assured/templates/java-testng/src/test/java/automation/api/ApiSpec.java +0 -29
- package/.claude/skills/rest-assured/templates/java-testng/src/test/java/automation/api/HealthApi.java +0 -21
- package/.claude/skills/rest-assured/templates/java-testng/src/test/java/automation/data/Cases.java +0 -45
- package/.claude/skills/rest-assured/templates/java-testng/src/test/java/automation/data/HealthData.java +0 -12
- package/.claude/skills/rest-assured/templates/java-testng/src/test/java/automation/data/ProductsData.java +0 -16
- package/.claude/skills/rest-assured/templates/java-testng/src/test/java/automation/tests/HealthTest.java +0 -15
- package/.claude/skills/rest-assured/templates/java-testng/src/test/java/automation/tests/ProductsTest.java +0 -37
- package/.claude/skills/selenium/templates/csharp-nunit/Components/AccountMenu.cs +0 -26
- package/.claude/skills/selenium/templates/csharp-nunit/Data/Cases.cs +0 -43
- package/.claude/skills/selenium/templates/csharp-nunit/Data/SignInData.cs +0 -24
- package/.claude/skills/selenium/templates/csharp-nunit/Flows/SignInFlow.cs +0 -51
- package/.claude/skills/selenium/templates/csharp-nunit/Framework/AutomationError.cs +0 -17
- package/.claude/skills/selenium/templates/csharp-nunit/Framework/DriverManager.cs +0 -26
- package/.claude/skills/selenium/templates/csharp-nunit/Pages/HomePage.cs +0 -28
- package/.claude/skills/selenium/templates/csharp-nunit/Pages/LoginPage.cs +0 -58
- package/.claude/skills/selenium/templates/csharp-nunit/Tests/BaseTest.cs +0 -22
- package/.claude/skills/selenium/templates/csharp-nunit/Tests/SmokeTests.cs +0 -37
- package/.claude/skills/selenium/templates/java-testng/src/test/java/automation/components/AccountMenu.java +0 -37
- package/.claude/skills/selenium/templates/java-testng/src/test/java/automation/data/Cases.java +0 -48
- package/.claude/skills/selenium/templates/java-testng/src/test/java/automation/data/SignInData.java +0 -36
- package/.claude/skills/selenium/templates/java-testng/src/test/java/automation/flows/SignInFlow.java +0 -60
- package/.claude/skills/selenium/templates/java-testng/src/test/java/automation/framework/Account.java +0 -19
- package/.claude/skills/selenium/templates/java-testng/src/test/java/automation/pages/HomePage.java +0 -45
- package/.claude/skills/selenium/templates/java-testng/src/test/java/automation/pages/LoginPage.java +0 -78
- package/.claude/skills/selenium/templates/java-testng/src/test/java/automation/tests/BaseTest.java +0 -33
- package/.claude/skills/selenium/templates/java-testng/src/test/java/automation/tests/SmokeTest.java +0 -33
- package/.claude/skills/selenium/templates/python-pytest/components/__init__.py +0 -1
- package/.claude/skills/selenium/templates/python-pytest/components/account_menu.py +0 -19
- package/.claude/skills/selenium/templates/python-pytest/data/accounts.py +0 -14
- package/.claude/skills/selenium/templates/python-pytest/data/cases.py +0 -33
- package/.claude/skills/selenium/templates/python-pytest/data/sign_in_data.py +0 -9
- package/.claude/skills/selenium/templates/python-pytest/flows/__init__.py +0 -0
- package/.claude/skills/selenium/templates/python-pytest/flows/sign_in.py +0 -61
- package/.claude/skills/selenium/templates/python-pytest/framework/__init__.py +0 -0
- package/.claude/skills/selenium/templates/python-pytest/framework/config.py +0 -90
- package/.claude/skills/selenium/templates/python-pytest/pages/__init__.py +0 -0
- package/.claude/skills/selenium/templates/python-pytest/pages/home_page.py +0 -23
- package/.claude/skills/selenium/templates/python-pytest/tests/test_smoke.py +0 -25
- /package/.claude/skills/karate/templates/java-junit5/src/test/java/{api → tests/api}/delete-product.feature +0 -0
- /package/.claude/skills/playwright/templates/{python/data/__init__.py → dotnet/auth/.gitkeep} +0 -0
- /package/.claude/skills/playwright/templates/{python/flows/__init__.py → javascript/auth/.gitkeep} +0 -0
- /package/.claude/skills/playwright/templates/{python/framework/__init__.py → project/auth/.gitkeep} +0 -0
- /package/.claude/skills/playwright/templates/project/{src → utils}/errors.ts +0 -0
- /package/.claude/skills/playwright/templates/python/{pages/__init__.py → auth/.gitkeep} +0 -0
- /package/.claude/skills/quality-checks/templates/playwright-ts/src/checks/{page-health.ts → pageHealth.ts} +0 -0
- /package/.claude/skills/quality-checks/templates/playwright-ts/src/{api/graphql.ts → services/graphqlClient.ts} +0 -0
- /package/.claude/skills/{requests/templates/python-pytest/api/__init__.py → selenium/templates/csharp-nunit/auth/.gitkeep} +0 -0
- /package/.claude/skills/{requests/templates/python-pytest/data/__init__.py → selenium/templates/java-testng/auth/.gitkeep} +0 -0
- /package/.claude/skills/selenium/templates/python-pytest/{data/__init__.py → auth/.gitkeep} +0 -0
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* The test cases, as data: one per behaviour. Each test's title is built from its case here, so a result traces
|
|
3
|
-
* back by id. Replace these with the story's cases (test-design step 3).
|
|
4
|
-
*/
|
|
5
|
-
|
|
6
|
-
/**
|
|
7
|
-
* One test case.
|
|
8
|
-
* @typedef {object} TestCase
|
|
9
|
-
* @property {string} id Case id, shared with the test title.
|
|
10
|
-
* @property {string} ac The acceptance criterion it covers.
|
|
11
|
-
* @property {string} title The behaviour, in the requirement's words.
|
|
12
|
-
* @property {string[]} preconditions What must be true before the steps.
|
|
13
|
-
* @property {string[]} steps What the test does.
|
|
14
|
-
* @property {string} data The data it uses (variable names, never secret values).
|
|
15
|
-
* @property {string} expected The change the test asserts.
|
|
16
|
-
* @property {string[]} postconditions What the test leaves behind.
|
|
17
|
-
* @property {boolean} [smoke] Also part of the smoke run.
|
|
18
|
-
*/
|
|
19
|
-
|
|
20
|
-
/** @type {Record<string, TestCase>} Every case of the story, keyed by id. */
|
|
21
|
-
const cases = {
|
|
22
|
-
'TS-0': {
|
|
23
|
-
id: 'TS-0', ac: 'AC-0', title: 'the test account signs in and the app greets the user', smoke: true,
|
|
24
|
-
preconditions: ['Signed out'], steps: ['Open the sign-in page', 'Enter the test account', 'Submit'],
|
|
25
|
-
data: 'E2E_USER, E2E_PASSWORD', expected: 'The home page greets the user', postconditions: ['Signed in'],
|
|
26
|
-
},
|
|
27
|
-
'TS-1': {
|
|
28
|
-
id: 'TS-1', ac: 'AC-0', title: 'a wrong password is refused with a message',
|
|
29
|
-
preconditions: ['Signed out'], steps: ['Open the sign-in page', 'Enter the user name and a wrong password', 'Submit'],
|
|
30
|
-
data: 'E2E_USER; a synthetic wrong password, unique per run', expected: 'The form shows the wrong-password message',
|
|
31
|
-
postconditions: ['Signed out'],
|
|
32
|
-
},
|
|
33
|
-
'TS-2': {
|
|
34
|
-
id: 'TS-2', ac: 'AC-0', title: 'signing out returns to the sign-in page',
|
|
35
|
-
preconditions: ['Signed in'], steps: ['Open the account menu', 'Sign out'],
|
|
36
|
-
data: 'E2E_USER, E2E_PASSWORD', expected: 'The sign-in page shows again', postconditions: ['Signed out'],
|
|
37
|
-
},
|
|
38
|
-
};
|
|
39
|
-
|
|
40
|
-
/**
|
|
41
|
-
* The title a test is registered under: case id, AC tag, behaviour, and `@smoke` when the case is in the smoke run.
|
|
42
|
-
* @param {TestCase} c The case.
|
|
43
|
-
* @returns {string} The title, e.g. "TS-0 @AC-0 the test account signs in … @smoke".
|
|
44
|
-
*/
|
|
45
|
-
function titleOf(c) {
|
|
46
|
-
return `${c.id} @${c.ac} ${c.title}${c.smoke ? ' @smoke' : ''}`;
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
module.exports = { cases, titleOf };
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Test data and expected results of the sign-in cases, taken from the requirement (never from what the page showed).
|
|
3
|
-
* Another story's data goes in its own file; pages and flows take these values as arguments.
|
|
4
|
-
*/
|
|
5
|
-
const signInData = {
|
|
6
|
-
/** What the app greets the signed-in test account with. */
|
|
7
|
-
greeting: '{{SIGNED_IN_TEXT}}',
|
|
8
|
-
/** The message for a wrong password. */
|
|
9
|
-
wrongPasswordMessage: '{{LOGIN_ERROR_TEXT}}',
|
|
10
|
-
};
|
|
11
|
-
|
|
12
|
-
module.exports = { signInData };
|
|
@@ -1,53 +0,0 @@
|
|
|
1
|
-
const { HomePage } = require('../pages/home.page');
|
|
2
|
-
const { LoginPage } = require('../pages/login.page');
|
|
3
|
-
|
|
4
|
-
/**
|
|
5
|
-
* The one sign-in every signed-in test uses: open the sign-in page, sign in, land on the home page.
|
|
6
|
-
*/
|
|
7
|
-
class SignInFlow {
|
|
8
|
-
/**
|
|
9
|
-
* @param {import('@playwright/test').Page} page The Playwright page to sign in on.
|
|
10
|
-
*/
|
|
11
|
-
constructor(page) {
|
|
12
|
-
this.page = page;
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
/**
|
|
16
|
-
* Signs in with an account and waits until the home page is ready (readiness, not an assertion).
|
|
17
|
-
* @param {{ user: string, password: string }} account The account to sign in with, from the data layer.
|
|
18
|
-
* @returns {Promise<HomePage>} The home page, for the test to assert on.
|
|
19
|
-
*/
|
|
20
|
-
async signIn(account) {
|
|
21
|
-
const login = await new LoginPage(this.page).open(LoginPage.path);
|
|
22
|
-
await login.signIn(account.user, account.password);
|
|
23
|
-
await login.waitUntilLeft();
|
|
24
|
-
const home = new HomePage(this.page);
|
|
25
|
-
await home.waitUntilReady();
|
|
26
|
-
return home;
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
/**
|
|
30
|
-
* Signs out through the account menu and waits until the sign-in page is back (readiness, not an assertion).
|
|
31
|
-
* @param {HomePage} home The signed-in home page.
|
|
32
|
-
* @returns {Promise<LoginPage>} The sign-in page, for the test to assert on.
|
|
33
|
-
*/
|
|
34
|
-
async signOut(home) {
|
|
35
|
-
await home.accountMenu().signOut();
|
|
36
|
-
const login = new LoginPage(this.page);
|
|
37
|
-
await login.waitUntilReady();
|
|
38
|
-
return login;
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
/**
|
|
42
|
-
* Submits the form with an account that should be refused, without waiting for a signed-in state.
|
|
43
|
-
* @param {{ user: string, password: string }} account The account to try.
|
|
44
|
-
* @returns {Promise<LoginPage>} The login page, for the test to assert on its error message.
|
|
45
|
-
*/
|
|
46
|
-
async attempt(account) {
|
|
47
|
-
const login = await new LoginPage(this.page).open(LoginPage.path);
|
|
48
|
-
await login.signIn(account.user, account.password);
|
|
49
|
-
return login;
|
|
50
|
-
}
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
module.exports = { SignInFlow };
|
|
@@ -1,59 +0,0 @@
|
|
|
1
|
-
const { AutomationError } = require('../errors');
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* What every page shares: one way to open a path and one way to wait until the page is usable.
|
|
5
|
-
* Pages hold locators and user actions only: no assertions, no API paths, no framework-private fields.
|
|
6
|
-
* Subclasses implement `readyMarker()`.
|
|
7
|
-
*/
|
|
8
|
-
class BasePage {
|
|
9
|
-
/**
|
|
10
|
-
* @param {import('@playwright/test').Page} page The Playwright page this object drives.
|
|
11
|
-
*/
|
|
12
|
-
constructor(page) {
|
|
13
|
-
this.page = page;
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
/**
|
|
17
|
-
* The element that is visible when this page is ready to use. Every page class overrides it.
|
|
18
|
-
* @returns {import('@playwright/test').Locator} Its locator.
|
|
19
|
-
*/
|
|
20
|
-
readyMarker() {
|
|
21
|
-
throw new AutomationError('Wait for', this.constructor.name, 'readyMarker() is not implemented');
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
/**
|
|
25
|
-
* Opens a path relative to `baseURL` and waits until the page is ready.
|
|
26
|
-
* Waits for `domcontentloaded`, then for the ready marker, so a page whose `load` event never fires can't hang the test.
|
|
27
|
-
* @param {string} path Path or full URL of the page; it is test data, never hardcoded in a page class.
|
|
28
|
-
* @returns {Promise<this>} This page, ready.
|
|
29
|
-
* @throws {AutomationError} With the URL and the HTTP status (or the network error) when the page doesn't open.
|
|
30
|
-
*/
|
|
31
|
-
async open(path) {
|
|
32
|
-
let response;
|
|
33
|
-
try {
|
|
34
|
-
response = await this.page.goto(path, { waitUntil: 'domcontentloaded' });
|
|
35
|
-
} catch (error) {
|
|
36
|
-
throw new AutomationError('Open', path, String(error).split('\n')[0]);
|
|
37
|
-
}
|
|
38
|
-
if (response && !response.ok()) {
|
|
39
|
-
throw new AutomationError('Open', response.url(), `HTTP ${response.status()}`);
|
|
40
|
-
}
|
|
41
|
-
await this.waitUntilReady();
|
|
42
|
-
return this;
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
/**
|
|
46
|
-
* Waits until the ready marker is visible.
|
|
47
|
-
* @returns {Promise<void>}
|
|
48
|
-
* @throws {AutomationError} Naming the URL and the page that never became ready.
|
|
49
|
-
*/
|
|
50
|
-
async waitUntilReady() {
|
|
51
|
-
try {
|
|
52
|
-
await this.readyMarker().waitFor({ state: 'visible' });
|
|
53
|
-
} catch {
|
|
54
|
-
throw new AutomationError('Wait for', this.page.url(), `${this.constructor.name} never became ready`);
|
|
55
|
-
}
|
|
56
|
-
}
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
module.exports = { BasePage };
|
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
const { AccountMenu } = require('../components/account-menu.component');
|
|
2
|
-
const { BasePage } = require('./base.page');
|
|
3
|
-
|
|
4
|
-
/** The page a signed-in user lands on. Exposes what tests assert on; holds no expected values. */
|
|
5
|
-
class HomePage extends BasePage {
|
|
6
|
-
/**
|
|
7
|
-
* The element that greets the signed-in user marks the page as ready.
|
|
8
|
-
* @returns {import('@playwright/test').Locator} Its locator.
|
|
9
|
-
*/
|
|
10
|
-
readyMarker() {
|
|
11
|
-
return this.greeting();
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
/**
|
|
15
|
-
* The element that greets the signed-in user, for tests to assert its text.
|
|
16
|
-
* @returns {import('@playwright/test').Locator} Its locator.
|
|
17
|
-
*/
|
|
18
|
-
greeting() {
|
|
19
|
-
return this.page.getByRole('{{SIGNED_IN_ROLE}}');
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
/**
|
|
23
|
-
* The account menu this page shows (shared with every signed-in page).
|
|
24
|
-
* @returns {AccountMenu} The component.
|
|
25
|
-
*/
|
|
26
|
-
accountMenu() {
|
|
27
|
-
return new AccountMenu(this.page);
|
|
28
|
-
}
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
module.exports = { HomePage };
|
|
@@ -1,56 +0,0 @@
|
|
|
1
|
-
const { BasePage } = require('./base.page');
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* The app's sign-in page. Locators come from the UI map (role and label first).
|
|
5
|
-
* A two-step form (identifier, Continue, then password) gets a second action here, not a second page class.
|
|
6
|
-
*/
|
|
7
|
-
class LoginPage extends BasePage {
|
|
8
|
-
/**
|
|
9
|
-
* The user name field marks the page as ready.
|
|
10
|
-
* @returns {import('@playwright/test').Locator} Its locator.
|
|
11
|
-
*/
|
|
12
|
-
readyMarker() {
|
|
13
|
-
return this.usernameField();
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
/**
|
|
17
|
-
* The user name field, for tests that check the sign-in page is showing.
|
|
18
|
-
* @returns {import('@playwright/test').Locator} Its locator.
|
|
19
|
-
*/
|
|
20
|
-
usernameField() {
|
|
21
|
-
return this.page.getByLabel('{{USERNAME_LABEL}}');
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
/**
|
|
25
|
-
* Signs in by filling the form and submitting it.
|
|
26
|
-
* @param {string} user The account's user name.
|
|
27
|
-
* @param {string} password The account's password.
|
|
28
|
-
* @returns {Promise<void>}
|
|
29
|
-
*/
|
|
30
|
-
async signIn(user, password) {
|
|
31
|
-
await this.page.getByLabel('{{USERNAME_LABEL}}').fill(user);
|
|
32
|
-
await this.page.getByLabel('{{PASSWORD_LABEL}}').fill(password);
|
|
33
|
-
await this.page.getByRole('button', { name: '{{SUBMIT_LABEL}}' }).click();
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
/**
|
|
37
|
-
* Waits until the sign-in form is gone, i.e. the app accepted the account and moved on (readiness, not an assertion).
|
|
38
|
-
* @returns {Promise<void>}
|
|
39
|
-
*/
|
|
40
|
-
async waitUntilLeft() {
|
|
41
|
-
await this.page.getByLabel('{{USERNAME_LABEL}}').waitFor({ state: 'hidden' });
|
|
42
|
-
}
|
|
43
|
-
|
|
44
|
-
/**
|
|
45
|
-
* The message the form shows when sign-in fails, for negative tests to assert on.
|
|
46
|
-
* @returns {import('@playwright/test').Locator} Its locator.
|
|
47
|
-
*/
|
|
48
|
-
errorMessage() {
|
|
49
|
-
return this.page.getByRole('alert');
|
|
50
|
-
}
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
/** Path of the sign-in page relative to BASE_URL (from the UI map). */
|
|
54
|
-
LoginPage.path = '{{LOGIN_PATH}}';
|
|
55
|
-
|
|
56
|
-
module.exports = { LoginPage };
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
const base = require('@playwright/test');
|
|
2
|
-
const { SignInFlow } = require('../src/flows/sign-in.flow');
|
|
3
|
-
const { LoginPage } = require('../src/pages/login.page');
|
|
4
|
-
|
|
5
|
-
/**
|
|
6
|
-
* The project's `test`: Playwright's, plus the page objects and flows each test gets, built here so specs never
|
|
7
|
-
* construct them. Specs import `test` and `expect` from this file.
|
|
8
|
-
*/
|
|
9
|
-
const test = base.test.extend({
|
|
10
|
-
/** The sign-in page object for the test's page. */
|
|
11
|
-
loginPage: async ({ page }, use) => {
|
|
12
|
-
await use(new LoginPage(page));
|
|
13
|
-
},
|
|
14
|
-
/** The sign-in flow for the test's page. */
|
|
15
|
-
signInFlow: async ({ page }, use) => {
|
|
16
|
-
await use(new SignInFlow(page));
|
|
17
|
-
},
|
|
18
|
-
});
|
|
19
|
-
|
|
20
|
-
module.exports = { test, expect: base.expect };
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
const { standardAccount, wrongPasswordAccount } = require('../src/data/accounts');
|
|
2
|
-
const { cases, titleOf } = require('../src/data/cases');
|
|
3
|
-
const { signInData } = require('../src/data/sign-in.data');
|
|
4
|
-
const { test, expect } = require('./fixtures');
|
|
5
|
-
|
|
6
|
-
test.describe('{{STORY_KEY}} sign-in', () => {
|
|
7
|
-
test(titleOf(cases['TS-0']), async ({ signInFlow }) => {
|
|
8
|
-
const home = await signInFlow.signIn(standardAccount());
|
|
9
|
-
await expect(home.greeting()).toHaveText(signInData.greeting);
|
|
10
|
-
});
|
|
11
|
-
|
|
12
|
-
test(titleOf(cases['TS-1']), async ({ signInFlow }) => {
|
|
13
|
-
const login = await signInFlow.attempt(wrongPasswordAccount());
|
|
14
|
-
await expect(login.errorMessage()).toHaveText(signInData.wrongPasswordMessage);
|
|
15
|
-
});
|
|
16
|
-
|
|
17
|
-
test(titleOf(cases['TS-2']), async ({ signInFlow }) => {
|
|
18
|
-
const home = await signInFlow.signIn(standardAccount());
|
|
19
|
-
const login = await signInFlow.signOut(home);
|
|
20
|
-
await expect(login.usernameField()).toBeVisible();
|
|
21
|
-
});
|
|
22
|
-
});
|
package/.claude/skills/playwright/templates/project/src/components/account-menu.component.ts
DELETED
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
import type { Locator, Page } from '@playwright/test';
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* The signed-in user's menu, shared by every page that shows it (a component, not a page: it has no URL of its own).
|
|
5
|
-
* Pages expose it; flows use its actions. No assertions here.
|
|
6
|
-
*/
|
|
7
|
-
export class AccountMenu {
|
|
8
|
-
/**
|
|
9
|
-
* @param page The Playwright page the menu is on.
|
|
10
|
-
*/
|
|
11
|
-
constructor(private readonly page: Page) {}
|
|
12
|
-
|
|
13
|
-
/**
|
|
14
|
-
* The sign-out control.
|
|
15
|
-
* @returns Its locator.
|
|
16
|
-
*/
|
|
17
|
-
signOutButton(): Locator {
|
|
18
|
-
return this.page.getByRole('button', { name: '{{SIGN_OUT_LABEL}}' });
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
/**
|
|
22
|
-
* Signs the user out.
|
|
23
|
-
*/
|
|
24
|
-
async signOut(): Promise<void> {
|
|
25
|
-
await this.signOutButton().click();
|
|
26
|
-
}
|
|
27
|
-
}
|
|
@@ -1,56 +0,0 @@
|
|
|
1
|
-
import { MissingSettingError } from './errors';
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* Settings of the suite, read in this one place.
|
|
5
|
-
* The runner entry (`playwright.config.ts`) loads the project's one `.env` into the environment;
|
|
6
|
-
* this module only reads `process.env`, and only when a value is used, so importing it never throws.
|
|
7
|
-
*/
|
|
8
|
-
|
|
9
|
-
/**
|
|
10
|
-
* Returns the value of a required setting.
|
|
11
|
-
* @param name Environment variable name, e.g. `E2E_USER`.
|
|
12
|
-
* @returns The value.
|
|
13
|
-
* @throws MissingSettingError when it isn't set.
|
|
14
|
-
*/
|
|
15
|
-
export function required(name: string): string {
|
|
16
|
-
const value = process.env[name];
|
|
17
|
-
if (!value) throw new MissingSettingError(name);
|
|
18
|
-
return value;
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
/**
|
|
22
|
-
* Returns the value of an optional setting.
|
|
23
|
-
* @param name Environment variable name.
|
|
24
|
-
* @returns The value, or `undefined` when it isn't set.
|
|
25
|
-
*/
|
|
26
|
-
export function optional(name: string): string | undefined {
|
|
27
|
-
return process.env[name] || undefined;
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
/** A test account: user name and password, read from the environment when used. */
|
|
31
|
-
export interface Account {
|
|
32
|
-
user: string;
|
|
33
|
-
password: string;
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
/**
|
|
37
|
-
* The test account the user gave (`E2E_USER`, `E2E_PASSWORD`).
|
|
38
|
-
* @returns The account; throws MissingSettingError naming the missing variable.
|
|
39
|
-
*/
|
|
40
|
-
export function testAccount(): Account {
|
|
41
|
-
return { user: required('E2E_USER'), password: required('E2E_PASSWORD') };
|
|
42
|
-
}
|
|
43
|
-
|
|
44
|
-
/**
|
|
45
|
-
* Login for the browser's own prompt (HTTP Basic or Digest), sent only to `BASE_URL`'s origin.
|
|
46
|
-
* Only `HTTP_USER`/`HTTP_PASSWORD`, never the test account: Playwright writes these into every failure trace
|
|
47
|
-
* (`trace.zip`), so they are set only for an app that really shows the prompt.
|
|
48
|
-
* @returns The credentials for Playwright's `httpCredentials`, or `undefined` when the app has no prompt.
|
|
49
|
-
*/
|
|
50
|
-
export function httpCredentials(): { username: string; password: string; origin: string } | undefined {
|
|
51
|
-
const base = optional('BASE_URL');
|
|
52
|
-
const username = optional('HTTP_USER');
|
|
53
|
-
const password = optional('HTTP_PASSWORD');
|
|
54
|
-
if (!base || !username || !password) return undefined;
|
|
55
|
-
return { username, password, origin: new URL(base).origin };
|
|
56
|
-
}
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import { testAccount, type Account } from '../config';
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* Accounts by role for the test cases. Values come from the environment through config; this file holds no secret.
|
|
5
|
-
*/
|
|
6
|
-
|
|
7
|
-
/**
|
|
8
|
-
* The account the user gave for this app.
|
|
9
|
-
* @returns It, read from `E2E_USER` and `E2E_PASSWORD` when called.
|
|
10
|
-
*/
|
|
11
|
-
export function standardAccount(): Account {
|
|
12
|
-
return testAccount();
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
/**
|
|
16
|
-
* An account the app must refuse: the real user name with a synthetic wrong password, unique per run.
|
|
17
|
-
* @returns The account.
|
|
18
|
-
*/
|
|
19
|
-
export function wrongPasswordAccount(): Account {
|
|
20
|
-
return { user: testAccount().user, password: `wrong-${Date.now()}` };
|
|
21
|
-
}
|
|
@@ -1,55 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* The test cases, as data: one per behaviour. Each test's title is built from its case here, so a result traces
|
|
3
|
-
* back by id. Replace these with the story's cases (test-design step 3).
|
|
4
|
-
*/
|
|
5
|
-
|
|
6
|
-
/** One test case. */
|
|
7
|
-
export interface TestCase {
|
|
8
|
-
/** Case id, shared with the test title. */
|
|
9
|
-
id: string;
|
|
10
|
-
/** The acceptance criterion it covers. */
|
|
11
|
-
ac: string;
|
|
12
|
-
/** The behaviour, in the requirement's words. */
|
|
13
|
-
title: string;
|
|
14
|
-
/** What must be true before the steps. */
|
|
15
|
-
preconditions: string[];
|
|
16
|
-
/** What the test does. */
|
|
17
|
-
steps: string[];
|
|
18
|
-
/** The data it uses (variable names, never secret values). */
|
|
19
|
-
data: string;
|
|
20
|
-
/** The change the test asserts. */
|
|
21
|
-
expected: string;
|
|
22
|
-
/** What the test leaves behind. */
|
|
23
|
-
postconditions: string[];
|
|
24
|
-
/** Also part of the smoke run. */
|
|
25
|
-
smoke?: boolean;
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
/** Every case of the story, keyed by id. */
|
|
29
|
-
export const cases = {
|
|
30
|
-
'TS-0': {
|
|
31
|
-
id: 'TS-0', ac: 'AC-0', title: 'the test account signs in and the app greets the user', smoke: true,
|
|
32
|
-
preconditions: ['Signed out'], steps: ['Open the sign-in page', 'Enter the test account', 'Submit'],
|
|
33
|
-
data: 'E2E_USER, E2E_PASSWORD', expected: 'The home page greets the user', postconditions: ['Signed in'],
|
|
34
|
-
},
|
|
35
|
-
'TS-1': {
|
|
36
|
-
id: 'TS-1', ac: 'AC-0', title: 'a wrong password is refused with a message',
|
|
37
|
-
preconditions: ['Signed out'], steps: ['Open the sign-in page', 'Enter the user name and a wrong password', 'Submit'],
|
|
38
|
-
data: 'E2E_USER; a synthetic wrong password, unique per run', expected: 'The form shows the wrong-password message',
|
|
39
|
-
postconditions: ['Signed out'],
|
|
40
|
-
},
|
|
41
|
-
'TS-2': {
|
|
42
|
-
id: 'TS-2', ac: 'AC-0', title: 'signing out returns to the sign-in page',
|
|
43
|
-
preconditions: ['Signed in'], steps: ['Open the account menu', 'Sign out'],
|
|
44
|
-
data: 'E2E_USER, E2E_PASSWORD', expected: 'The sign-in page shows again', postconditions: ['Signed out'],
|
|
45
|
-
},
|
|
46
|
-
} satisfies Record<string, TestCase>;
|
|
47
|
-
|
|
48
|
-
/**
|
|
49
|
-
* The title a test is registered under: case id, AC tag, behaviour, and `@smoke` when the case is in the smoke run.
|
|
50
|
-
* @param c The case.
|
|
51
|
-
* @returns The title, e.g. "TS-0 @AC-0 the test account signs in … @smoke".
|
|
52
|
-
*/
|
|
53
|
-
export function titleOf(c: TestCase): string {
|
|
54
|
-
return `${c.id} @${c.ac} ${c.title}${c.smoke ? ' @smoke' : ''}`;
|
|
55
|
-
}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Test data and expected results of the sign-in cases, taken from the requirement (never from what the page showed).
|
|
3
|
-
* Another story's data goes in its own file; pages and flows take these values as arguments.
|
|
4
|
-
*/
|
|
5
|
-
export const signInData = {
|
|
6
|
-
/** What the app greets the signed-in test account with. */
|
|
7
|
-
greeting: '{{SIGNED_IN_TEXT}}',
|
|
8
|
-
/** The message for a wrong password. */
|
|
9
|
-
wrongPasswordMessage: '{{LOGIN_ERROR_TEXT}}',
|
|
10
|
-
};
|
|
@@ -1,51 +0,0 @@
|
|
|
1
|
-
import type { Page } from '@playwright/test';
|
|
2
|
-
import type { Account } from '../config';
|
|
3
|
-
import { HomePage } from '../pages/home.page';
|
|
4
|
-
import { LoginPage } from '../pages/login.page';
|
|
5
|
-
|
|
6
|
-
/**
|
|
7
|
-
* The one sign-in every signed-in test uses: open the sign-in page, sign in, land on the home page.
|
|
8
|
-
*/
|
|
9
|
-
export class SignInFlow {
|
|
10
|
-
/**
|
|
11
|
-
* @param page The Playwright page to sign in on.
|
|
12
|
-
*/
|
|
13
|
-
constructor(private readonly page: Page) {}
|
|
14
|
-
|
|
15
|
-
/**
|
|
16
|
-
* Signs in with an account and waits until the home page is ready (readiness, not an assertion).
|
|
17
|
-
* @param account The account to sign in with, from the data layer.
|
|
18
|
-
* @returns The home page, for the test to assert on.
|
|
19
|
-
*/
|
|
20
|
-
async signIn(account: Account): Promise<HomePage> {
|
|
21
|
-
const login = await new LoginPage(this.page).open(LoginPage.path);
|
|
22
|
-
await login.signIn(account.user, account.password);
|
|
23
|
-
await login.waitUntilLeft();
|
|
24
|
-
const home = new HomePage(this.page);
|
|
25
|
-
await home.waitUntilReady();
|
|
26
|
-
return home;
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
/**
|
|
30
|
-
* Signs out through the account menu and waits until the sign-in page is back (readiness, not an assertion).
|
|
31
|
-
* @param home The signed-in home page.
|
|
32
|
-
* @returns The sign-in page, for the test to assert on.
|
|
33
|
-
*/
|
|
34
|
-
async signOut(home: HomePage): Promise<LoginPage> {
|
|
35
|
-
await home.accountMenu().signOut();
|
|
36
|
-
const login = new LoginPage(this.page);
|
|
37
|
-
await login.waitUntilReady();
|
|
38
|
-
return login;
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
/**
|
|
42
|
-
* Submits the form with an account that should be refused, without waiting for a signed-in state.
|
|
43
|
-
* @param account The account to try.
|
|
44
|
-
* @returns The login page, for the test to assert on its error message.
|
|
45
|
-
*/
|
|
46
|
-
async attempt(account: Account): Promise<LoginPage> {
|
|
47
|
-
const login = await new LoginPage(this.page).open(LoginPage.path);
|
|
48
|
-
await login.signIn(account.user, account.password);
|
|
49
|
-
return login;
|
|
50
|
-
}
|
|
51
|
-
}
|
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
import type { Locator, Page } from '@playwright/test';
|
|
2
|
-
import { AutomationError } from '../errors';
|
|
3
|
-
|
|
4
|
-
/**
|
|
5
|
-
* What every page shares: one way to open a path and one way to wait until the page is usable.
|
|
6
|
-
* Pages hold locators and user actions only: no assertions, no API paths, no framework-private fields.
|
|
7
|
-
*/
|
|
8
|
-
export abstract class BasePage {
|
|
9
|
-
/**
|
|
10
|
-
* @param page The Playwright page this object drives.
|
|
11
|
-
*/
|
|
12
|
-
constructor(protected readonly page: Page) {}
|
|
13
|
-
|
|
14
|
-
/**
|
|
15
|
-
* The element that is visible when this page is ready to use (a heading, a form field, a list).
|
|
16
|
-
* @returns Its locator.
|
|
17
|
-
*/
|
|
18
|
-
protected abstract readyMarker(): Locator;
|
|
19
|
-
|
|
20
|
-
/**
|
|
21
|
-
* Opens a path relative to `baseURL` and waits until the page is ready.
|
|
22
|
-
* Waits for `domcontentloaded`, then for the ready marker, so a page whose `load` event never fires can't hang the test.
|
|
23
|
-
* @param path Path or full URL of the page; it is test data, never hardcoded in a page class.
|
|
24
|
-
* @returns This page, ready.
|
|
25
|
-
* @throws AutomationError with the URL and the HTTP status (or the network error) when the page doesn't open.
|
|
26
|
-
*/
|
|
27
|
-
async open(path: string): Promise<this> {
|
|
28
|
-
let response;
|
|
29
|
-
try {
|
|
30
|
-
response = await this.page.goto(path, { waitUntil: 'domcontentloaded' });
|
|
31
|
-
} catch (error) {
|
|
32
|
-
throw new AutomationError('Open', path, String(error).split('\n')[0]);
|
|
33
|
-
}
|
|
34
|
-
if (response && !response.ok()) {
|
|
35
|
-
throw new AutomationError('Open', response.url(), `HTTP ${response.status()}`);
|
|
36
|
-
}
|
|
37
|
-
await this.waitUntilReady();
|
|
38
|
-
return this;
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
/**
|
|
42
|
-
* Waits until the ready marker is visible.
|
|
43
|
-
* @throws AutomationError naming the URL and the page that never became ready.
|
|
44
|
-
*/
|
|
45
|
-
async waitUntilReady(): Promise<void> {
|
|
46
|
-
try {
|
|
47
|
-
await this.readyMarker().waitFor({ state: 'visible' });
|
|
48
|
-
} catch {
|
|
49
|
-
throw new AutomationError('Wait for', this.page.url(), `${this.constructor.name} never became ready`);
|
|
50
|
-
}
|
|
51
|
-
}
|
|
52
|
-
}
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
import type { Locator } from '@playwright/test';
|
|
2
|
-
import { AccountMenu } from '../components/account-menu.component';
|
|
3
|
-
import { BasePage } from './base.page';
|
|
4
|
-
|
|
5
|
-
/** The page a signed-in user lands on. Exposes what tests assert on; holds no expected values. */
|
|
6
|
-
export class HomePage extends BasePage {
|
|
7
|
-
/**
|
|
8
|
-
* The element that greets the signed-in user marks the page as ready.
|
|
9
|
-
* @returns Its locator.
|
|
10
|
-
*/
|
|
11
|
-
protected readyMarker(): Locator {
|
|
12
|
-
return this.greeting();
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
/**
|
|
16
|
-
* The element that greets the signed-in user, for tests to assert its text.
|
|
17
|
-
* @returns Its locator.
|
|
18
|
-
*/
|
|
19
|
-
greeting(): Locator {
|
|
20
|
-
return this.page.getByRole('{{SIGNED_IN_ROLE}}');
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
/**
|
|
24
|
-
* The account menu this page shows (shared with every signed-in page).
|
|
25
|
-
* @returns The component.
|
|
26
|
-
*/
|
|
27
|
-
accountMenu(): AccountMenu {
|
|
28
|
-
return new AccountMenu(this.page);
|
|
29
|
-
}
|
|
30
|
-
}
|
|
@@ -1,53 +0,0 @@
|
|
|
1
|
-
import type { Locator } from '@playwright/test';
|
|
2
|
-
import { BasePage } from './base.page';
|
|
3
|
-
|
|
4
|
-
/**
|
|
5
|
-
* The app's sign-in page. Locators come from the UI map (role and label first).
|
|
6
|
-
* A two-step form (identifier, Continue, then password) gets a second action here, not a second page class.
|
|
7
|
-
*/
|
|
8
|
-
export class LoginPage extends BasePage {
|
|
9
|
-
/** Path of the sign-in page relative to BASE_URL (from the UI map). */
|
|
10
|
-
static readonly path = '{{LOGIN_PATH}}';
|
|
11
|
-
|
|
12
|
-
/**
|
|
13
|
-
* The user name field marks the page as ready.
|
|
14
|
-
* @returns Its locator.
|
|
15
|
-
*/
|
|
16
|
-
protected readyMarker(): Locator {
|
|
17
|
-
return this.usernameField();
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
/**
|
|
21
|
-
* The user name field, for tests that check the sign-in page is showing.
|
|
22
|
-
* @returns Its locator.
|
|
23
|
-
*/
|
|
24
|
-
usernameField(): Locator {
|
|
25
|
-
return this.page.getByLabel('{{USERNAME_LABEL}}');
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
/**
|
|
29
|
-
* Signs in by filling the form and submitting it.
|
|
30
|
-
* @param user The account's user name.
|
|
31
|
-
* @param password The account's password.
|
|
32
|
-
*/
|
|
33
|
-
async signIn(user: string, password: string): Promise<void> {
|
|
34
|
-
await this.page.getByLabel('{{USERNAME_LABEL}}').fill(user);
|
|
35
|
-
await this.page.getByLabel('{{PASSWORD_LABEL}}').fill(password);
|
|
36
|
-
await this.page.getByRole('button', { name: '{{SUBMIT_LABEL}}' }).click();
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
/**
|
|
40
|
-
* Waits until the sign-in form is gone, i.e. the app accepted the account and moved on (readiness, not an assertion).
|
|
41
|
-
*/
|
|
42
|
-
async waitUntilLeft(): Promise<void> {
|
|
43
|
-
await this.page.getByLabel('{{USERNAME_LABEL}}').waitFor({ state: 'hidden' });
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
/**
|
|
47
|
-
* The message the form shows when sign-in fails, for negative tests to assert on.
|
|
48
|
-
* @returns Its locator.
|
|
49
|
-
*/
|
|
50
|
-
errorMessage(): Locator {
|
|
51
|
-
return this.page.getByRole('alert');
|
|
52
|
-
}
|
|
53
|
-
}
|