testeiya 0.10.0 → 0.10.2

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.
Files changed (241) hide show
  1. package/PIPELINES.md +3 -0
  2. package/README.md +10 -20
  3. package/dist/prompt/clis.d.ts +7 -0
  4. package/dist/prompt/pipeline-report.d.ts +1 -0
  5. package/dist/prompt/report.d.ts +10 -0
  6. package/dist/prompt/system-prompt.d.ts +22 -0
  7. package/dist/prompt/system-prompt.js +1 -1
  8. package/dist/prompt/system-prompt.js.map +1 -1
  9. package/dist/prompt/testomat.io.d.ts +19 -0
  10. package/dist/prompt/thread.d.ts +73 -0
  11. package/dist/src/args.d.ts +39 -0
  12. package/dist/src/attribution-extension.d.ts +3 -0
  13. package/dist/src/checkpoint.d.ts +30 -0
  14. package/dist/src/cli.d.ts +2 -0
  15. package/dist/src/cli.js +27 -32
  16. package/dist/src/cli.js.map +1 -1
  17. package/dist/src/doctor.d.ts +11 -0
  18. package/dist/src/env.d.ts +30 -0
  19. package/dist/src/exec.d.ts +11 -0
  20. package/dist/src/git.d.ts +41 -0
  21. package/dist/src/git.js +10 -0
  22. package/dist/src/git.js.map +1 -1
  23. package/dist/src/langfuse-extension.d.ts +7 -0
  24. package/dist/src/langfuse.d.ts +67 -0
  25. package/dist/src/mcp.d.ts +19 -0
  26. package/dist/src/model.d.ts +20 -0
  27. package/dist/src/model.js +2 -0
  28. package/dist/src/model.js.map +1 -1
  29. package/dist/src/models.d.ts +1 -0
  30. package/dist/src/output.d.ts +84 -0
  31. package/dist/src/pipeline/command-stage.d.ts +12 -0
  32. package/dist/src/pipeline/crash-guard.d.ts +12 -0
  33. package/dist/src/pipeline/crash-guard.js +21 -0
  34. package/dist/src/pipeline/crash-guard.js.map +1 -0
  35. package/dist/src/pipeline/diagram.d.ts +24 -0
  36. package/dist/src/pipeline/gate.d.ts +21 -0
  37. package/dist/src/pipeline/launcher.d.ts +33 -0
  38. package/dist/src/pipeline/launcher.js +16 -3
  39. package/dist/src/pipeline/launcher.js.map +1 -1
  40. package/dist/src/pipeline/log.d.ts +29 -0
  41. package/dist/src/pipeline/log.js +9 -0
  42. package/dist/src/pipeline/log.js.map +1 -1
  43. package/dist/src/pipeline/overlay.d.ts +29 -0
  44. package/dist/src/pipeline/pipeline-file.d.ts +44 -0
  45. package/dist/src/pipeline/pipeline-file.js +16 -8
  46. package/dist/src/pipeline/pipeline-file.js.map +1 -1
  47. package/dist/src/pipeline/pipeline.d.ts +78 -0
  48. package/dist/src/pipeline/pipeline.js +33 -7
  49. package/dist/src/pipeline/pipeline.js.map +1 -1
  50. package/dist/src/pipeline/report.d.ts +26 -0
  51. package/dist/src/pipeline/report.js +13 -0
  52. package/dist/src/pipeline/report.js.map +1 -1
  53. package/dist/src/pipeline/spec.d.ts +63 -0
  54. package/dist/src/pipeline/stage-env.d.ts +13 -0
  55. package/dist/src/pipeline/stage-env.js +31 -0
  56. package/dist/src/pipeline/stage-env.js.map +1 -0
  57. package/dist/src/pipeline/stage.d.ts +71 -0
  58. package/dist/src/pipeline/stage.js.map +1 -1
  59. package/dist/src/pipeline/state.d.ts +63 -0
  60. package/dist/src/pipeline/summary-stage.d.ts +24 -0
  61. package/dist/src/pipeline/task-stage.d.ts +24 -0
  62. package/dist/src/pipeline/task-stage.js +86 -2
  63. package/dist/src/pipeline/task-stage.js.map +1 -1
  64. package/dist/src/pipeline/variables.d.ts +20 -0
  65. package/dist/src/result.d.ts +6 -0
  66. package/dist/src/run.d.ts +69 -0
  67. package/dist/src/run.js +116 -60
  68. package/dist/src/run.js.map +1 -1
  69. package/dist/src/session.d.ts +43 -0
  70. package/dist/src/session.js +3 -1
  71. package/dist/src/session.js.map +1 -1
  72. package/dist/src/sessions.d.ts +23 -0
  73. package/dist/src/skills.d.ts +29 -0
  74. package/package.json +11 -2
  75. package/pipelines/api-testing.yml +16 -5
  76. package/pipelines/issue-test-cases.yml +3 -4
  77. package/pipelines/pr-review.yml +14 -5
  78. package/pipelines/regression.yml +1 -0
  79. package/pipelines/web-testing.yml +1 -0
  80. package/prompt/system-prompt.ts +1 -1
  81. package/scripts/vendor-skills.js +62 -0
  82. package/skills/codeceptjs/ci-fix-tests/SKILL.md +0 -119
  83. package/skills/codeceptjs/codeceptjs-auth/SKILL.md +0 -141
  84. package/skills/codeceptjs/codeceptjs-exploration/SKILL.md +0 -100
  85. package/skills/codeceptjs/codeceptjs-fundamentals/SKILL.md +0 -196
  86. package/skills/codeceptjs/codeceptjs-run-analysis/SKILL.md +0 -83
  87. package/skills/codeceptjs/debugging-codeceptjs-tests/SKILL.md +0 -126
  88. package/skills/codeceptjs/lint-codeceptjs-tests/SKILL.md +0 -104
  89. package/skills/codeceptjs/migrate-codeceptjs-4/SKILL.md +0 -109
  90. package/skills/codeceptjs/migrate-cypress-to-codeceptjs/SKILL.md +0 -295
  91. package/skills/codeceptjs/migrate-protractor-to-codeceptjs/SKILL.md +0 -339
  92. package/skills/codeceptjs/migrate-selenium-java-to-codeceptjs/SKILL.md +0 -459
  93. package/skills/codeceptjs/migrate-testcafe-to-codeceptjs/SKILL.md +0 -338
  94. package/skills/codeceptjs/refactoring-codeceptjs-tests/SKILL.md +0 -78
  95. package/skills/codeceptjs/writing-codeceptjs-tests/SKILL.md +0 -102
  96. package/skills/playwright/playwright-best-practices/SKILL.md +0 -303
  97. package/skills/playwright/playwright-best-practices/advanced/authentication-flows.md +0 -360
  98. package/skills/playwright/playwright-best-practices/advanced/authentication.md +0 -871
  99. package/skills/playwright/playwright-best-practices/advanced/clock-mocking.md +0 -364
  100. package/skills/playwright/playwright-best-practices/advanced/mobile-testing.md +0 -409
  101. package/skills/playwright/playwright-best-practices/advanced/multi-context.md +0 -288
  102. package/skills/playwright/playwright-best-practices/advanced/multi-user.md +0 -393
  103. package/skills/playwright/playwright-best-practices/advanced/network-advanced.md +0 -452
  104. package/skills/playwright/playwright-best-practices/advanced/third-party.md +0 -464
  105. package/skills/playwright/playwright-best-practices/architecture/pom-vs-fixtures.md +0 -363
  106. package/skills/playwright/playwright-best-practices/architecture/test-architecture.md +0 -369
  107. package/skills/playwright/playwright-best-practices/architecture/when-to-mock.md +0 -383
  108. package/skills/playwright/playwright-best-practices/browser-apis/browser-apis.md +0 -391
  109. package/skills/playwright/playwright-best-practices/browser-apis/iframes.md +0 -403
  110. package/skills/playwright/playwright-best-practices/browser-apis/service-workers.md +0 -504
  111. package/skills/playwright/playwright-best-practices/browser-apis/websockets.md +0 -403
  112. package/skills/playwright/playwright-best-practices/core/annotations.md +0 -424
  113. package/skills/playwright/playwright-best-practices/core/assertions-waiting.md +0 -361
  114. package/skills/playwright/playwright-best-practices/core/configuration.md +0 -452
  115. package/skills/playwright/playwright-best-practices/core/fixtures-hooks.md +0 -417
  116. package/skills/playwright/playwright-best-practices/core/global-setup.md +0 -434
  117. package/skills/playwright/playwright-best-practices/core/locators.md +0 -242
  118. package/skills/playwright/playwright-best-practices/core/page-object-model.md +0 -315
  119. package/skills/playwright/playwright-best-practices/core/projects-dependencies.md +0 -453
  120. package/skills/playwright/playwright-best-practices/core/test-data.md +0 -492
  121. package/skills/playwright/playwright-best-practices/core/test-suite-structure.md +0 -361
  122. package/skills/playwright/playwright-best-practices/core/test-tags.md +0 -298
  123. package/skills/playwright/playwright-best-practices/debugging/console-errors.md +0 -420
  124. package/skills/playwright/playwright-best-practices/debugging/debugging.md +0 -504
  125. package/skills/playwright/playwright-best-practices/debugging/error-testing.md +0 -360
  126. package/skills/playwright/playwright-best-practices/debugging/flaky-tests.md +0 -496
  127. package/skills/playwright/playwright-best-practices/frameworks/angular.md +0 -530
  128. package/skills/playwright/playwright-best-practices/frameworks/nextjs.md +0 -469
  129. package/skills/playwright/playwright-best-practices/frameworks/react.md +0 -531
  130. package/skills/playwright/playwright-best-practices/frameworks/vue.md +0 -574
  131. package/skills/playwright/playwright-best-practices/infrastructure-ci-cd/ci-cd.md +0 -468
  132. package/skills/playwright/playwright-best-practices/infrastructure-ci-cd/docker.md +0 -283
  133. package/skills/playwright/playwright-best-practices/infrastructure-ci-cd/github-actions.md +0 -546
  134. package/skills/playwright/playwright-best-practices/infrastructure-ci-cd/gitlab.md +0 -397
  135. package/skills/playwright/playwright-best-practices/infrastructure-ci-cd/other-providers.md +0 -521
  136. package/skills/playwright/playwright-best-practices/infrastructure-ci-cd/parallel-sharding.md +0 -371
  137. package/skills/playwright/playwright-best-practices/infrastructure-ci-cd/performance.md +0 -453
  138. package/skills/playwright/playwright-best-practices/infrastructure-ci-cd/reporting.md +0 -424
  139. package/skills/playwright/playwright-best-practices/infrastructure-ci-cd/test-coverage.md +0 -497
  140. package/skills/playwright/playwright-best-practices/testing-patterns/accessibility.md +0 -359
  141. package/skills/playwright/playwright-best-practices/testing-patterns/api-testing.md +0 -719
  142. package/skills/playwright/playwright-best-practices/testing-patterns/browser-extensions.md +0 -506
  143. package/skills/playwright/playwright-best-practices/testing-patterns/canvas-webgl.md +0 -493
  144. package/skills/playwright/playwright-best-practices/testing-patterns/component-testing.md +0 -500
  145. package/skills/playwright/playwright-best-practices/testing-patterns/drag-drop.md +0 -576
  146. package/skills/playwright/playwright-best-practices/testing-patterns/electron.md +0 -509
  147. package/skills/playwright/playwright-best-practices/testing-patterns/file-operations.md +0 -377
  148. package/skills/playwright/playwright-best-practices/testing-patterns/file-upload-download.md +0 -562
  149. package/skills/playwright/playwright-best-practices/testing-patterns/forms-validation.md +0 -561
  150. package/skills/playwright/playwright-best-practices/testing-patterns/graphql-testing.md +0 -331
  151. package/skills/playwright/playwright-best-practices/testing-patterns/i18n.md +0 -508
  152. package/skills/playwright/playwright-best-practices/testing-patterns/performance-testing.md +0 -476
  153. package/skills/playwright/playwright-best-practices/testing-patterns/security-testing.md +0 -430
  154. package/skills/playwright/playwright-best-practices/testing-patterns/visual-regression.md +0 -634
  155. package/skills/playwright/playwright-cli/SKILL.md +0 -489
  156. package/skills/playwright/playwright-cli/references/element-attributes.md +0 -23
  157. package/skills/playwright/playwright-cli/references/playwright-tests.md +0 -39
  158. package/skills/playwright/playwright-cli/references/pr-attachments.md +0 -60
  159. package/skills/playwright/playwright-cli/references/request-mocking.md +0 -87
  160. package/skills/playwright/playwright-cli/references/running-code.md +0 -245
  161. package/skills/playwright/playwright-cli/references/session-management.md +0 -227
  162. package/skills/playwright/playwright-cli/references/storage-state.md +0 -275
  163. package/skills/playwright/playwright-cli/references/test-generation.md +0 -433
  164. package/skills/playwright/playwright-cli/references/tracing.md +0 -139
  165. package/skills/playwright/playwright-cli/references/video-recording.md +0 -216
  166. package/skills/skills.lock.json +0 -89
  167. package/skills/skills.yaml +0 -35
  168. /package/skills/{testomatio/explorbot → explorbot}/explorbot-fundamentals/SKILL.md +0 -0
  169. /package/skills/{testomatio/explorbot → explorbot}/explorbot-fundamentals/references/no-install.md +0 -0
  170. /package/skills/{testomatio/explorbot → explorbot}/explorbot-plan/SKILL.md +0 -0
  171. /package/skills/{testomatio/explorbot → explorbot}/explorbot-setup/SKILL.md +0 -0
  172. /package/skills/{testomatio/explorbot → explorbot}/prima/SKILL.md +0 -0
  173. /package/skills/{testomatio/qa-process → qa-process}/qa-lead-strategy-advisor/SKILL.md +0 -0
  174. /package/skills/{testomatio/qa-process → qa-process}/qa-lead-strategy-advisor/references/output-format.md +0 -0
  175. /package/skills/{testomatio/qa-process → qa-process}/qa-review-pr/SKILL.md +0 -0
  176. /package/skills/{testomatio/qa-process → qa-process}/testing-workflow/SKILL.md +0 -0
  177. /package/skills/{testomatio/requirements → requirements}/catalog-features/SKILL.md +0 -0
  178. /package/skills/{testomatio/requirements → requirements}/catalog-features/references/layout.md +0 -0
  179. /package/skills/{testomatio/requirements → requirements}/detect-product-mismatches/SKILL.md +0 -0
  180. /package/skills/{testomatio/requirements → requirements}/detect-product-mismatches/references/features.md +0 -0
  181. /package/skills/{testomatio/requirements → requirements}/detect-product-mismatches/references/layout.md +0 -0
  182. /package/skills/{testomatio/requirements → requirements}/pull-request-diff-analyzer/SKILL.md +0 -0
  183. /package/skills/{testomatio/requirements → requirements}/qa-explain-behavior/SKILL.md +0 -0
  184. /package/skills/{testomatio/requirements → requirements}/qa-explain-behavior/references/answer-shapes.md +0 -0
  185. /package/skills/{testomatio/requirements → requirements}/qa-explain-behavior/references/examples.md +0 -0
  186. /package/skills/{testomatio/requirements → requirements}/qa-pr-requirements-analyzer/SKILL.md +0 -0
  187. /package/skills/{testomatio/requirements → requirements}/qa-pr-requirements-analyzer/references/summary-example.md +0 -0
  188. /package/skills/{testomatio/requirements → requirements}/qa-requirement-reviewer/SKILL.md +0 -0
  189. /package/skills/{testomatio/requirements → requirements}/qa-requirement-reviewer/references/requirements_reviewer_examples.md +0 -0
  190. /package/skills/{testomatio/requirements → requirements}/qa-thinking/SKILL.md +0 -0
  191. /package/skills/{testomatio/requirements → requirements}/wiki-from-code/SKILL.md +0 -0
  192. /package/skills/{testomatio/requirements → requirements}/wiki-from-code/references/behaviors.md +0 -0
  193. /package/skills/{testomatio/requirements → requirements}/wiki-from-code/references/layout.md +0 -0
  194. /package/skills/{testomatio/requirements → requirements}/write-user-story/SKILL.md +0 -0
  195. /package/skills/{testomatio/test-automation → test-automation}/automate-manual-test-cases/CLAUDE.md +0 -0
  196. /package/skills/{testomatio/test-automation → test-automation}/automate-manual-test-cases/SKILL.md +0 -0
  197. /package/skills/{testomatio/test-automation → test-automation}/automate-manual-test-cases/references/CODECEPTJS_BEST_PRACTICES.md +0 -0
  198. /package/skills/{testomatio/test-automation → test-automation}/automate-manual-test-cases/references/FINAL_SUMMARY_TEMPLATE.md +0 -0
  199. /package/skills/{testomatio/test-automation → test-automation}/automate-manual-test-cases/references/PLAYWRIGHT_BEST_PRACTICES.md +0 -0
  200. /package/skills/{testomatio/test-automation → test-automation}/automate-manual-test-cases/references/POM_BEST_PRACTICES.md +0 -0
  201. /package/skills/{testomatio/test-automation → test-automation}/automate-manual-test-cases/references/TEST_DATA_MANAGEMENT.md +0 -0
  202. /package/skills/{testomatio/test-automation → test-automation}/debug-fix-failed-flaky-autotests/SKILL.md +0 -0
  203. /package/skills/{testomatio/test-automation → test-automation}/debug-fix-failed-flaky-autotests/references/DEBUGGING_QUICK_REFERENCE.md +0 -0
  204. /package/skills/{testomatio/test-automation → test-automation}/epic-requirements-specification/SKILL.md +0 -0
  205. /package/skills/{testomatio/test-automation → test-automation}/qa-automation-test-consolidation/SKILL.md +0 -0
  206. /package/skills/{testomatio/test-automation → test-automation}/qa-data-seeder/SKILL.md +0 -0
  207. /package/skills/{testomatio/test-automation → test-automation}/run-tests-with-testomatio-reporter/SKILL.md +0 -0
  208. /package/skills/{testomatio/test-automation → test-automation}/setup-change-aware-pr-testing/SKILL.md +0 -0
  209. /package/skills/{testomatio/test-automation → test-automation}/setup-ci-automation/SKILL.md +0 -0
  210. /package/skills/{testomatio/test-automation → test-automation}/testomat-allure-adapter/SKILL.md +0 -0
  211. /package/skills/{testomatio/test-management → test-management}/detect-duplicate-test-cases/SKILL.md +0 -0
  212. /package/skills/{testomatio/test-management → test-management}/detect-duplicate-test-cases/references/DUPLICATE_INSTRUCTIONS.md +0 -0
  213. /package/skills/{testomatio/test-management → test-management}/detect-useless-tests/SKILL.md +0 -0
  214. /package/skills/{testomatio/test-management → test-management}/improve-test-cases/SKILL.md +0 -0
  215. /package/skills/{testomatio/test-management → test-management}/improve-test-cases/references/TESTOMAT_MARKDOWN_EXAMPLE.md +0 -0
  216. /package/skills/{testomatio/test-management → test-management}/migrate-to-testomatio/SKILL.md +0 -0
  217. /package/skills/{testomatio/test-management → test-management}/migrate-to-testomatio/references/CSV_MIGRATION.md +0 -0
  218. /package/skills/{testomatio/test-management → test-management}/migrate-to-testomatio/references/CUSTOM_MIGRATION.md +0 -0
  219. /package/skills/{testomatio/test-management → test-management}/migrate-to-testomatio/references/TESTMO_MIGRATION.md +0 -0
  220. /package/skills/{testomatio/test-management → test-management}/migrate-to-testomatio/references/TESTRAIL_MIGRATION.md +0 -0
  221. /package/skills/{testomatio/test-management → test-management}/migrate-to-testomatio/references/XRAY_MIGRATION.md +0 -0
  222. /package/skills/{testomatio/test-management → test-management}/qa-e2e-tests-reporting/SKILL.md +0 -0
  223. /package/skills/{testomatio/test-management → test-management}/qa-e2e-tests-reporting/references/TESTOMATIO_ARTIFACTS.md +0 -0
  224. /package/skills/{testomatio/test-management → test-management}/qa-e2e-tests-reporting/references/TESTOMATIO_HTML_REPORT.md +0 -0
  225. /package/skills/{testomatio/test-management → test-management}/qa-e2e-tests-reporting/references/TESTOMATIO_REPORTERS_CONFIG.md +0 -0
  226. /package/skills/{testomatio/test-management → test-management}/qa-split-testing-levels-pyramid/SKILL.md +0 -0
  227. /package/skills/{testomatio/test-management → test-management}/qa-sprint-report-by-testomatio/SKILL.md +0 -0
  228. /package/skills/{testomatio/test-management → test-management}/qa-sprint-report-by-testomatio/references/qa-sprint-report.md +0 -0
  229. /package/skills/{testomatio/test-management → test-management}/qa-test-code-coverage/SKILL.md +0 -0
  230. /package/skills/{testomatio/test-management → test-management}/qa-test-code-coverage/references/COVERAGE_FILE_FORMAT.md +0 -0
  231. /package/skills/{testomatio/test-management → test-management}/qa-test-code-coverage/references/E2E_FRAMEWORKS.md +0 -0
  232. /package/skills/{testomatio/test-management → test-management}/qa-test-code-coverage/scripts/check-coverage.mjs +0 -0
  233. /package/skills/{testomatio/test-management → test-management}/qa-write-test-cases/SKILL.md +0 -0
  234. /package/skills/{testomatio/test-management → test-management}/qa-write-test-cases/references/test-case-format.md +0 -0
  235. /package/skills/{testomatio/test-management → test-management}/qa-write-test-cases/references/testomat-tms-guide.md +0 -0
  236. /package/skills/{testomatio/test-management → test-management}/qa-write-test-cases/references/writing-rule.md +0 -0
  237. /package/skills/{testomatio/test-management → test-management}/scan-automation-project/SKILL.md +0 -0
  238. /package/skills/{testomatio/test-management → test-management}/sync-test-cases-with-tms/SKILL.md +0 -0
  239. /package/skills/{testomatio/test-management → test-management}/sync-test-cases-with-tms/references/TESTOMATIO_CLI.md +0 -0
  240. /package/skills/{testomatio/test-management → test-management}/testomatio-mcp/SKILL.md +0 -0
  241. /package/skills/{testomatio/test-management → test-management}/testomatio-mcp/references/MCP_SETUP.md +0 -0
@@ -0,0 +1,43 @@
1
+ import { DefaultResourceLoader, ModelRuntime, SettingsManager, type AgentSession, type ExtensionFactory, type SessionManager, type Skill } from "@earendil-works/pi-coding-agent";
2
+ import { type RunResult } from "./result.js";
3
+ export declare const BUNDLED_SKILLS_DIR: string;
4
+ /** The one runtime factory, so every command reads the same auth. */
5
+ export declare function createRuntime(): Promise<ModelRuntime>;
6
+ /**
7
+ * The loader every command shares, so `doctor` reports the skills a run would
8
+ * actually load. A filter, not a loader: pi also discovers skills from the
9
+ * checkout it is pointed at (`.agents/skills`, `.pi/skills`, and the user's
10
+ * own), and an arbitrary CI clone must not be able to hand the model its own.
11
+ */
12
+ export declare function createLoader(options: LoaderOptions): DefaultResourceLoader;
13
+ export declare function createTesteiyaSession(options: SessionOptions): Promise<CreatedSession>;
14
+ export interface LoaderOptions {
15
+ cwd: string;
16
+ settingsManager: SettingsManager;
17
+ extensionPaths: string[];
18
+ extensionFactories?: ExtensionFactory[];
19
+ systemPrompt: () => string;
20
+ }
21
+ export interface SessionOptions {
22
+ cwd: string;
23
+ result: RunResult;
24
+ sessionManager: SessionManager;
25
+ model?: string;
26
+ outputFile?: string;
27
+ brief?: boolean;
28
+ /** Whole prompt sections this run contributes (the pull request thread rules).
29
+ * Built from the resolved model, which the caller cannot know before this. */
30
+ sections?: (model: string) => string[];
31
+ /** Where this run sits in its thread, so the prompt says first or continuing. */
32
+ threadMode?: "first" | "continuing";
33
+ connection?: {
34
+ tokenAvailable?: boolean;
35
+ };
36
+ backendUrl?: string;
37
+ }
38
+ export interface CreatedSession {
39
+ session: AgentSession;
40
+ model: string;
41
+ /** What the run can reach — the list a `/name` in the task is matched against. */
42
+ skills: Skill[];
43
+ }
@@ -21,7 +21,9 @@ const SUBAGENTS_EXTENSION = dirname(createRequire(import.meta.url).resolve("pi-s
21
21
  export async function createRuntime() {
22
22
  const runtime = await ModelRuntime.create({
23
23
  authPath: join(TESTEIYA_HOME, "auth.json"),
24
- modelsPath: null,
24
+ // A run inside Testeiya Cloud points its providers at the cloud's own AI
25
+ // proxy by handing the CLI a models.json; anywhere else this stays unset.
26
+ modelsPath: process.env.TESTEIYA_MODELS_JSON ?? null,
25
27
  });
26
28
  await applyEnvKeys(runtime);
27
29
  return runtime;
@@ -1 +1 @@
1
- {"version":3,"file":"session.js","sourceRoot":"","sources":["../../src/session.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AACrC,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAC5C,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AAC1C,OAAO,EACL,kBAAkB,EAClB,uBAAuB,EACvB,kBAAkB,EAClB,qBAAqB,EACrB,YAAY,EACZ,eAAe,GAKhB,MAAM,iCAAiC,CAAC;AACzC,OAAO,EAAE,iBAAiB,EAAE,MAAM,4BAA4B,CAAC;AAC/D,OAAO,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAC7C,OAAO,EAAE,YAAY,EAAE,YAAY,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AACrE,OAAO,EAAE,cAAc,EAAE,MAAM,eAAe,CAAC;AAC/C,OAAO,EAAE,MAAM,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,UAAU,CAAC;AACxD,OAAO,EAAE,YAAY,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AACxD,OAAO,EAAE,mBAAmB,EAAkB,MAAM,aAAa,CAAC;AAClE,OAAO,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AAE7C,4EAA4E;AAC5E,+EAA+E;AAC/E,MAAM,CAAC,MAAM,kBAAkB,GAAG,IAAI,CAAC,YAAY,EAAE,QAAQ,CAAC,CAAC;AAE/D,MAAM,qBAAqB,GAAG,aAAa,CAAC,uBAAuB,CAAC,CAAC;AACrE,MAAM,kBAAkB,GAAG,aAAa,CAA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ACjD,CAAC"}
@@ -0,0 +1,23 @@
1
+ import { SessionManager } from "@earendil-works/pi-coding-agent";
2
+ /**
3
+ * Sessions are pi's, not ours: it stores, lists and reopens them under
4
+ * PI_STATE_DIR, or in the one file `--session-file` names. `--no-session` keeps
5
+ * a run entirely in memory.
6
+ */
7
+ export declare function openSessionManager(cwd: string, args: SessionArgs): Promise<SessionManager | string>;
8
+ /** The model a resumed session was last running, so `-c` needs no --model. */
9
+ export declare function sessionModel(manager: SessionManager): SavedModel | null;
10
+ export declare function runSessions(cwd: string, json?: boolean): Promise<number>;
11
+ /** Long enough to clear the UUIDv7 timestamp prefix, which repeats per minute. */
12
+ export declare function shortId(id: string): string;
13
+ export interface SessionArgs {
14
+ continueLast?: boolean;
15
+ resume?: string;
16
+ session?: string;
17
+ sessionFile?: string;
18
+ noSession?: boolean;
19
+ }
20
+ export interface SavedModel {
21
+ provider: string;
22
+ modelId: string;
23
+ }
@@ -0,0 +1,29 @@
1
+ import { type ResourceDiagnostic, type Skill } from "@earendil-works/pi-coding-agent";
2
+ /**
3
+ * A skill named in the task loads before the run: `/qa-thinking` puts that
4
+ * SKILL.md in front of the prompt. pi does not do this for us — its own
5
+ * `/skill:name` form expands only with prompt templates on, and a task carrying
6
+ * a comment from a stranger never runs with those on. A name we do not ship
7
+ * stays plain text, so `/testeiya` in a comment is still just words.
8
+ */
9
+ export declare function expandSkills(prompt: string, skills: Skill[]): Expanded;
10
+ /**
11
+ * The skills a run can actually reach. Loaded through the loader every command
12
+ * shares, so this list, `doctor` and the model's own list cannot drift — and a
13
+ * checkout's skills are filtered out here exactly as they are in a run.
14
+ */
15
+ export declare function loadBundledSkills(): Promise<BundledSkills>;
16
+ export declare function runSkills(pattern?: string, json?: boolean): Promise<number>;
17
+ export interface Group {
18
+ group: string;
19
+ skills: Skill[];
20
+ }
21
+ export interface Expanded {
22
+ prompt: string;
23
+ loaded: string[];
24
+ }
25
+ export interface BundledSkills {
26
+ count: number;
27
+ groups: Group[];
28
+ diagnostics: ResourceDiagnostic[];
29
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "testeiya",
3
- "version": "0.10.0",
3
+ "version": "0.10.2",
4
4
  "description": "AI testing agent — QA-focused coding agent for manual and automated tests",
5
5
  "type": "module",
6
6
  "license": "MIT",
@@ -12,9 +12,18 @@
12
12
  "bin": {
13
13
  "testeiya": "dist/src/cli.js"
14
14
  },
15
+ "exports": {
16
+ "./prompt/*.js": {
17
+ "types": "./dist/prompt/*.d.ts",
18
+ "default": "./dist/prompt/*.js"
19
+ },
20
+ "./scripts/vendor-skills.js": "./scripts/vendor-skills.js",
21
+ "./package.json": "./package.json"
22
+ },
15
23
  "files": [
16
24
  "dist",
17
25
  "prompt",
26
+ "scripts",
18
27
  "pipelines",
19
28
  "PIPELINES.md",
20
29
  "skills",
@@ -30,7 +39,7 @@
30
39
  "scripts": {
31
40
  "start": "npm run build && node dist/src/cli.js",
32
41
  "dev": "./testeiya",
33
- "build": "tsc -p tsconfig.json",
42
+ "build": "rm -rf dist && tsc -p tsconfig.json",
34
43
  "typecheck": "tsc -p tsconfig.json --noEmit",
35
44
  "prepublishOnly": "npm run build",
36
45
  "test": "npm run build && node --test test/*.test.js"
@@ -1,10 +1,11 @@
1
1
  name: api-testing
2
2
  description: Find the API endpoints a pull request changed, test each with Explorbot, explain what broke.
3
+ target: pr
3
4
 
4
5
  gates:
5
6
  api:
6
- env: [EXPLORBOT_URL, EXPLORBOT_API_SPEC]
7
- message: No API to test. Set EXPLORBOT_URL to the API base and EXPLORBOT_API_SPEC to its OpenAPI spec.
7
+ env: [EXPLORBOT_URL, OPENAPI_SPEC]
8
+ message: No API to test. Set EXPLORBOT_URL to the API base and OPENAPI_SPEC to its OpenAPI spec.
8
9
  explorbot-ai:
9
10
  env: [EXPLORBOT_AI_PROVIDER]
10
11
  message: Explorbot has no AI provider. Set EXPLORBOT_AI_PROVIDER and its key.
@@ -13,13 +14,23 @@ env:
13
14
  EXPLORBOT_NO_BANNER: "1"
14
15
 
15
16
  stages:
17
+ - id: spec
18
+ title: OpenAPI spec
19
+ emoji: 📜
20
+ when: [api]
21
+ run: npx -y @apidevtools/swagger-cli validate "$OPENAPI_SPEC"
22
+ stopOn: fail
23
+ timeout: 2m
24
+
16
25
  - id: review
17
- title: Pull request review
26
+ title: API review
18
27
  emoji: 🔍
19
28
  session: qa
29
+ when: [api]
20
30
  task: |
21
- Review this pull request as a QA engineer. /qa-review-pr
31
+ Review this pull request for public API changes
22
32
  List the API endpoints it adds or changes in endpoints.txt, one path per line like /users/{id}, empty if none.
33
+
23
34
  outputs: [endpoints.txt]
24
35
 
25
36
  - id: explore
@@ -27,7 +38,7 @@ stages:
27
38
  emoji: 🤖
28
39
  when: [api, explorbot-ai]
29
40
  each_line: endpoints.txt
30
- run: EXPLORBOT_OUTPUT="$STAGE_DIR/explorbot" npx -y explorbot api explore "$ITEM" --style psycho
41
+ run: EXPLORBOT_OUTPUT="$STAGE_DIR/explorbot" npx -y explorbot api explore "$ITEM" --spec "$OPENAPI_SPEC"
31
42
  outputs: [explorbot/]
32
43
  timeout: 10m
33
44
 
@@ -1,13 +1,14 @@
1
1
  name: issue-test-cases
2
2
  description: Turn an issue or epic into test cases, and sync them to Testomat.io.
3
+ target: issue
3
4
 
4
5
  gates:
5
6
  issue:
6
7
  env: [ISSUE_URL]
7
8
  message: No issue. Set ISSUE_URL to the issue or epic to cover.
8
9
  testomatio:
9
- env: [TESTOMATIO, TESTOMATIO_PROJECT_ID]
10
- message: No Testomat.io project. Set TESTOMATIO and TESTOMATIO_PROJECT_ID.
10
+ env: [TESTOMATIO]
11
+ message: No Testomat.io project. Set TESTOMATIO API Key to import test cases
11
12
 
12
13
  when: [issue]
13
14
 
@@ -36,7 +37,5 @@ stages:
36
37
  title: Sync to Testomat.io
37
38
  emoji: 🔄
38
39
  when: [testomatio]
39
- each_file: test-cases/*.md
40
40
  task: |
41
41
  Sync the test cases in ${ITEM} to Testomat.io. /sync-test-cases-with-tms
42
- Skip a case that already exists there.
@@ -1,5 +1,6 @@
1
1
  name: pr-review
2
2
  description: Review a pull request, propose test cases for it, and sync them to Testomat.io.
3
+ target: pr
3
4
 
4
5
  gates:
5
6
  code-changed:
@@ -7,12 +8,20 @@ gates:
7
8
  min_files: 3
8
9
  ignore: ["**/*.md", "**/*.lock", "docs/**"]
9
10
  message: Fewer than 3 code files changed.
11
+ testcases-needed:
12
+ env: [CREATE_TESTCASES]
13
+ message: 'No test cases created. Enable test case creation via CREATE_TESTCASES env var'
10
14
  testomatio:
11
- env: [TESTOMATIO, TESTOMATIO_PROJECT_ID]
12
- message: No Testomat.io project. Set TESTOMATIO and TESTOMATIO_PROJECT_ID.
15
+ env: [TESTOMATIO]
16
+ message: No Testomat.io project. Set TESTOMATIO.
13
17
 
14
18
  when: [code-changed]
15
19
 
20
+ env:
21
+ # feature/add-login → feature-add-login
22
+ TESTOMATIO_BRANCH: ${GIT_BRANCH | slugify}
23
+
24
+
16
25
  stages:
17
26
  - id: requirements
18
27
  title: Requirements
@@ -31,7 +40,9 @@ stages:
31
40
  title: Test cases
32
41
  emoji: 📝
33
42
  session: writer
43
+ when: [testcases-needed]
34
44
  task: |
45
+ If there is linked issue and it was already reviewed by Testeiya and have linked tests - skip this step
35
46
  Write test cases for this pull request from requirements.md and review.md. /qa-write-test-cases
36
47
  Put them in test-cases/, one markdown file per suite.
37
48
  inputs: [requirements.md, review.md]
@@ -40,8 +51,6 @@ stages:
40
51
  - id: sync
41
52
  title: Sync to Testomat.io
42
53
  emoji: 🔄
43
- when: [testomatio]
44
- each_file: test-cases/*.md
54
+ when: [testomatio, testcases-needed]
45
55
  task: |
46
56
  Sync the test cases in ${ITEM} to Testomat.io. /sync-test-cases-with-tms
47
- Skip a case that already exists there.
@@ -1,5 +1,6 @@
1
1
  name: regression
2
2
  description: Run the tests a change can break, from the coverage map, then explain the failures.
3
+ target: pr
3
4
 
4
5
  gates:
5
6
  coverage:
@@ -1,5 +1,6 @@
1
1
  name: web-testing
2
2
  description: Review a pull request, test the change in a browser with Explorbot, explain what broke.
3
+ target: pr
3
4
 
4
5
  gates:
5
6
  staging:
@@ -15,7 +15,7 @@ export function buildSystemPrompt(options: SystemPromptOptions): string {
15
15
  const date = new Date().toISOString().split("T")[0];
16
16
  const clis = options.connectedClis?.join(", ") || "none connected yet";
17
17
  const mcps = options.connectedMcps?.join(", ") || "none connected yet";
18
- let manualTestsHint = " Pulled manual tests usually live in `.testeiya/manual-tests/`; check there before declaring the project has no manual tests.";
18
+ let manualTestsHint = " Pulled manual tests usually live in `.testeiya/test-cases/`; check there before declaring the project has no manual tests.";
19
19
  if (options.manualTestsHint === false) manualTestsHint = "";
20
20
 
21
21
  const prompt = dedent`
@@ -0,0 +1,62 @@
1
+ /**
2
+ * Copies the skills of testomatio/skills into skills/<plugin>/<skill>/.
3
+ *
4
+ * Every release runs it, and the vendored folders are gitignored, so a release
5
+ * that skips it ships no skills. Plain Node: the release workflow has no build step.
6
+ *
7
+ * node scripts/vendor-skills.js
8
+ */
9
+ import { cpSync, existsSync, mkdirSync, mkdtempSync, readdirSync, readFileSync, rmSync } from "node:fs";
10
+ import { execFileSync } from "node:child_process";
11
+ import { tmpdir } from "node:os";
12
+ import { join } from "node:path";
13
+ import { fileURLToPath } from "node:url";
14
+
15
+ export const SKILLS_REPO = "https://github.com/testomatio/skills.git";
16
+ export const SKILLS_OUTPUT = join(import.meta.dirname, "..", "skills");
17
+
18
+ /**
19
+ * Clones the repo and copies each plugin's skills into a folder named after the
20
+ * plugin. The folder is the category hosts show. A skill two plugins list lands
21
+ * in the first one only.
22
+ */
23
+ export class SkillsVendor {
24
+ constructor({ outputDir = SKILLS_OUTPUT, repo = SKILLS_REPO } = {}) {
25
+ this.outputDir = outputDir;
26
+ this.repo = repo;
27
+ }
28
+
29
+ async update() {
30
+ const clone = mkdtempSync(join(tmpdir(), "testeiya-skills-"));
31
+ try {
32
+ execFileSync("git", ["clone", "-q", "--depth", "1", this.repo, clone], { stdio: "pipe" });
33
+ rmSync(this.outputDir, { recursive: true, force: true });
34
+ const copied = this.#copyPlugins(clone);
35
+ console.log(`Vendored ${copied} skills from ${this.repo} into ${this.outputDir}`);
36
+ } finally {
37
+ rmSync(clone, { recursive: true, force: true });
38
+ }
39
+ }
40
+
41
+ // A plugin's skills/ entries link to the repo's skills/<name>. Only the names
42
+ // are read: a Windows clone without symlinks turns the links into text files.
43
+ #copyPlugins(clone) {
44
+ const marketplace = JSON.parse(readFileSync(join(clone, ".claude-plugin", "marketplace.json"), "utf-8"));
45
+ const seen = new Set();
46
+ for (const plugin of marketplace.plugins ?? []) {
47
+ const entries = join(clone, plugin.source, "skills");
48
+ if (!existsSync(entries)) continue;
49
+ for (const name of readdirSync(entries)) {
50
+ const from = join(clone, "skills", name);
51
+ if (seen.has(name) || !existsSync(join(from, "SKILL.md"))) continue;
52
+ seen.add(name);
53
+ const to = join(this.outputDir, plugin.name, name);
54
+ mkdirSync(to, { recursive: true });
55
+ cpSync(from, to, { recursive: true, dereference: true });
56
+ }
57
+ }
58
+ return seen.size;
59
+ }
60
+ }
61
+
62
+ if (process.argv[1] === fileURLToPath(import.meta.url)) await new SkillsVendor().update();
@@ -1,119 +0,0 @@
1
- ---
2
- name: ci-fix-tests
3
- description: "Use on CI in non-interactive mode after a failed CodeceptJS run — attempts safe fixes only (locator drift, missing waits), reruns failing scenarios, rolls back edits that didn't help, reports at `output/ci-fix.md`. No refactors, no config edits, no flake-masking. Trigger on \"ci fix tests\", \"auto-fix failing tests\", \"attempt repair on CI\", or as a CI step after a failed run."
4
- ---
5
-
6
- # Auto-fix CodeceptJS Tests on CI
7
-
8
- A non-interactive auto-repair loop. Reads the failed-tests baseline from `output/` (where `aiTrace` left trace artifacts), attempts a small set of safe fixes, reruns only the failing scenarios, compares, and writes a report at `output/ci-fix.md`. Rolls back any edit that didn't help.
9
-
10
- **Conservative by design.** CI is not the place to restructure tests, change abstractions, or fix anything that needs human judgement. The goal is "pass the run". Anything riskier is escalated through the report.
11
-
12
- This skill assumes a working **git** checkout — rollback uses `git checkout -- <file>` to restore originals.
13
-
14
- ## Workflow
15
-
16
- ### 1. Read the baseline failures
17
- Use the **codeceptjs-run-analysis** skill against the existing `output/trace_*/` artifacts to enumerate every failing scenario. Record:
18
-
19
- - the **set** of failing tests (file path + scenario name)
20
- - the failed step in each, and the locator / wait / assertion involved
21
- - a cluster signature per failure (so unique vs systemic is clear)
22
-
23
- Save this as the **baseline** — `count`, `failing_set`, `clusters`.
24
-
25
- ### 2. Pick safe fix candidates
26
- Only attempt fixes from this allowed list:
27
-
28
- - **Locator drift** — the failed locator no longer matches anything but a similar element exists. Use the **codeceptjs-exploration** skill (headless) to find candidates; pick a short locator scoped to a stable region — `I.click('Save', '.toolbar')` — in this order: visible text / accessible name → ARIA `{ role, name }` → `$name` (`customLocator`) → composed CSS. Replace the locator at the failing step only.
29
- - **Missing wait for a spinner / loader / modal** — the failed step's ARIA snapshot shows a spinner or skeleton present, or the target element appears later. Add a single matching `I.waitFor*` immediately before the failing step.
30
- - **`I.wait(N)` replacement** — when a hardcoded sleep is the only thing between a failing assertion and a passing one and the gating element is identifiable, replace the sleep with a specific `waitFor*`.
31
-
32
- **Do not attempt:**
33
- - Auth / credential / env-var fixes — those are CI configuration, not test code.
34
- - Refactoring (extracting page objects, custom helpers, splitting scenarios).
35
- - Renaming Scenarios or tags — CI's `--grep` and pipelines reference them.
36
- - Adding `retries: N` to a Scenario — masking flake is a human decision.
37
- - Anything outside the failing test file (no `codecept.conf.*`, no helper, no PO edits).
38
-
39
- If a failure doesn't match any allowed-fix pattern, **skip it** and record it as `unresolved` for the report.
40
-
41
- ### 3. Apply edits and rerun
42
- Track every modification: file path, line number, before/after snippet, fix kind. Then rerun **only the failing scenarios** under the same config CI used:
43
-
44
- ```bash
45
- npx codeceptjs run --grep '<scenario>|<scenario>|...'
46
- ```
47
-
48
- Find the right config via `package.json` scripts or the CI workflow file. Match the worker count if `run-workers` was used originally.
49
-
50
- ### 4. Compare against the baseline
51
- Use **codeceptjs-run-analysis** again to enumerate the failing set after the fix.
52
-
53
- | New failing-set vs baseline | Status |
54
- |---|---|
55
- | Empty (zero failures) | `SUCCESS_FULL` |
56
- | Strict subset of the baseline | `SUCCESS_PARTIAL` |
57
- | Identical set | `NO_IMPROVEMENT` |
58
- | Larger, or contains a test not in baseline | `REGRESSED` |
59
-
60
- ### 5. Decide: keep or roll back
61
-
62
- - `SUCCESS_FULL` / `SUCCESS_PARTIAL` → **keep** the edits.
63
- - `NO_IMPROVEMENT` / `REGRESSED` → **roll back every edit** with `git checkout -- <files>`. The on-disk state at the end of the skill must be identical to what it was at the start.
64
-
65
- A regression is treated the same as no improvement — the attempt didn't work, the working state is what was on disk before. Don't try to "undo only the bad ones" — the whole batch goes.
66
-
67
- ### 6. Write the report (always)
68
- Write `output/ci-fix.md` regardless of outcome — CI reads it to surface results.
69
-
70
- ## Report format
71
-
72
- ```markdown
73
- # CI Fix Report — <ISO timestamp>
74
-
75
- **Status:** SUCCESS_FULL | SUCCESS_PARTIAL | NO_IMPROVEMENT | REGRESSED
76
-
77
- ## Baseline
78
- Failing scenarios: N
79
- - `tests/foo_test.js` — "user can log in"
80
- - `tests/bar_test.js` — "checkout flow"
81
- - ...
82
-
83
- ## Attempted fixes
84
- - `tests/foo_test.js:42` — locator drift: `I.click('Save')` → `I.click('Save', '.toolbar')`
85
- - `tests/bar_test.js:15` — added `I.waitForInvisible('.spinner')` before checkout click
86
- - `tests/baz_test.js:7` — replaced `I.wait(3)` with `I.waitForVisible('.confirmation-dialog', 10)`
87
-
88
- ## Result
89
- Failing scenarios after fix: M (was N)
90
- - Resolved: `tests/foo_test.js` — "user can log in"
91
- - Still failing: `tests/bar_test.js` — "checkout flow"
92
- - New failures (REGRESSED only): `tests/baz_test.js` — "edit profile"
93
-
94
- ## Failure clusters (NO_IMPROVEMENT / REGRESSED only)
95
- - **Cluster A (3 scenarios)** — `Element not found: button.btn-primary`. Likely a deploy regression or design change.
96
- - **Cluster B (1 scenario)** — `Navigation timeout to /checkout`. Possible backend issue.
97
-
98
- ## Discarded changes (NO_IMPROVEMENT / REGRESSED only)
99
- - `tests/foo_test.js` — restored
100
- - `tests/bar_test.js` — restored
101
- - `tests/baz_test.js` — restored
102
- ```
103
-
104
- The first line of `Status:` is the machine-parseable signal. The rest is for the human reading the failed CI build.
105
-
106
- ## Things to avoid
107
-
108
- - Editing files outside the failing test files. Config, helpers, page objects, and CI workflows are off-limits in this mode.
109
- - Attempting more than one fix kind on the same scenario in one pass. Fix one thing, observe, then try another.
110
- - `retries: N` to mask flakiness — human decision.
111
- - Skipping rollback on `NO_IMPROVEMENT`. Even no-op edits can confuse the next run or the next reviewer.
112
- - Writing a partial or missing `output/ci-fix.md`. CI depends on it; the absence of a report is itself a failure mode.
113
- - Running the **whole** suite for the verification step — only the originally-failing scenarios, to keep CI time bounded.
114
-
115
- ## Related skills
116
-
117
- - `codeceptjs-run-analysis` — baseline, clustering, post-fix comparison
118
- - `codeceptjs-exploration` — replacement locators for drift
119
- - `codeceptjs-fundamentals` — config, helper, CI environment
@@ -1,141 +0,0 @@
1
- ---
2
- name: codeceptjs-auth
3
- description: >
4
- Use when a CodeceptJS test needs login, user roles, or session reuse — or
5
- when another CodeceptJS skill identifies authorization is required. Also on
6
- auth-related test failures. Trigger on login, sign-in, sign-up,
7
- authentication, sessions, "logged in", admin/editor/user roles.
8
- ---
9
-
10
- # CodeceptJS Auth Plugin
11
-
12
- The `auth` plugin logs each user in once, captures cookies (or localStorage/token via overrides), and restores the session for subsequent tests. Stale sessions trigger a fresh login automatically.
13
-
14
- If the project already has `auth` configured (fundamentals' discovery output), **reuse** its existing inject name and user keys — don't reconfigure.
15
-
16
- ## Decide first — ask the user
17
-
18
- Four answers shape the plugin. Don't guess any.
19
-
20
- 1. **Is a session needed at all?** Public flows (landing, signup) → skip the plugin.
21
- 2. **One user or many?** Default one; add more only when actually exercised.
22
- 3. **If many — what splits them?** Role, workspace/tenant, plan tier, sign-in provider, per-test fixture — real systems vary. Ask; use the answer to name `users.<key>` entries.
23
- 4. **What's the auth type?**
24
- - **Form** — default; canonical shape below
25
- - **OAuth / SSO** — click provider button, drive the IdP page (often separate origin)
26
- - **Magic link / passwordless** — UI flow rarely worth automating; prefer an API mint or reading the link from a test mailbox
27
- - **API token** — skip the form; write the token into `localStorage` via `executeScript`, or `I.setCookie(...)`
28
- - **2FA / OTP** — async `login`; fetch the code from a test mailbox / backdoor before submitting
29
-
30
- ## Rules
31
-
32
- 1. **Login flow never lives in the conf.** Put it in `steps_file.js` (if included) or a page object; conf only references it: `login: (I) => I.login()`.
33
- 2. **Credentials from env only** — `.env` loaded via `process.loadEnvFile()` (no dotenv dependency). Passwords wrapped with `secret(...)`. No literals anywhere — conf, steps file, test, git history.
34
- 3. **`.env` is gitignored; `.env.example` is committed** with names, no values. Gitignore `output/*_session.json` too.
35
-
36
- ## Canonical shape
37
-
38
- ```js
39
- // codecept.conf.js — first line of the file
40
- process.loadEnvFile()
41
-
42
- export const config = {
43
- include: { I: './steps_file.js' },
44
- plugins: {
45
- auth: {
46
- enabled: true,
47
- saveToFile: true,
48
- users: {
49
- admin: {
50
- login: (I) => I.login(),
51
- check: (I) => I.see('Welcome, User', '.navbar'),
52
- },
53
- },
54
- },
55
- },
56
- }
57
- ```
58
-
59
- ```js
60
- // steps_file.js
61
- import { secret } from 'codeceptjs'
62
- const { I } = inject()
63
-
64
- export default function () {
65
- return actor({
66
- login() {
67
- I.amOnPage('/login')
68
- I.fillField('Email', process.env.ADMIN_EMAIL)
69
- I.fillField('Password', secret(process.env.ADMIN_PASSWORD))
70
- I.click('Sign in')
71
- },
72
- })
73
- }
74
- ```
75
-
76
- ```sh
77
- # .env (gitignored) # .env.example (committed)
78
- USER_EMAIL=... USER_EMAIL=
79
- USER_PASSWORD=<secret> USER_PASSWORD=
80
- ```
81
-
82
- ## Pre-flight (before writing config)
83
-
84
- 1. **Read the real login page** — MCP `run_code` to `/login`, inspect the ARIA snapshot (`codeceptjs-exploration`). Field labels / `name` / `id` / submit control from the actual page, not guesses. Unclear authorization mechanism → ask the user.
85
- 2. **Pick a role-specific post-login marker** — something rendered only for *this* user (navbar username, `data-user-role`).
86
- 3. **Confirm session storage** — cookies (default) for server-rendered apps; localStorage/sessionStorage for SPAs. Verify after a manual login with `I.executeScript(() => Object.keys(localStorage))`. Cookie fetch/restore silently no-op against token storage.
87
-
88
- ## Verify
89
-
90
- Run a one-Scenario file that calls `login(<role>)` then asserts on the post-login marker:
91
-
92
- ```bash
93
- npx codeceptjs run --grep '<scenario>' --debug # real run, not dry — dry-run doesn't init plugins
94
- ```
95
-
96
- Enable `saveToFile: true` only after this round-trip succeeds — a bad saved session masks a broken `login`.
97
-
98
- Then wire into hooks/tests: `Before(({ login }) => login())` for suite-wide, or per-test as needed.
99
-
100
- ## Multi-role shape
101
-
102
- Only after question 3 is answered. Keys named after whatever splits users *in this system*; one matching actor method per key:
103
-
104
- ```js
105
- users: {
106
- admin: { login: (I) => I.loginAsAdmin() },
107
- workspaceB: { login: (I) => I.loginToWorkspaceB() },
108
- }
109
- ```
110
-
111
- Don't parameterise into a single `login(key)` — the plugin keys sessions by name, explicit methods read better. Switch mid-Scenario: `session('<key>')` opens a parallel browser context (fundamentals § Writing tests).
112
-
113
- ## Token / localStorage auth
114
-
115
- Override `fetch` / `restore` when sessions live outside cookies:
116
-
117
- ```js
118
- admin: {
119
- login: (I) => I.loginAsAdmin(),
120
- check: (I) => I.see('Admin', '.navbar'),
121
- fetch: (I) => I.executeScript(() => localStorage.getItem('session_id')),
122
- restore: (I, session) => {
123
- I.amOnPage('/')
124
- I.executeScript((s) => localStorage.setItem('session_id', s), session)
125
- },
126
- }
127
- ```
128
-
129
- `check(I, session)` receives whatever `fetch` returned — throw inside `check` to force fresh login (e.g. `/me` endpoint shows wrong user).
130
-
131
- ## Pitfalls
132
-
133
- - Credentials inlined in conf/test — always env-driven + `secret()`.
134
- - Forgetting to gitignore `.env` and `output/*_session.json` — both leak credentials.
135
-
136
- ## Related skills
137
-
138
- - `codeceptjs-fundamentals` — secrets rule, sessions, config mutation trap
139
- - `codeceptjs-exploration` — reading the live login page
140
- - `writing-codeceptjs-tests` / `refactoring-codeceptjs-tests` — invoke this skill when auth is identified
141
- - `debugging-codeceptjs-tests` — auth-related failure patterns