Bug 40447 - Add documentation for cypress plugins
Summary: Add documentation for cypress plugins
Status: Needs Signoff
Alias: None
Product: Koha
Classification: Unclassified
Component: Test Suite (show other bugs)
Version: Main
Hardware: All All
: P5 - low enhancement
Assignee: Martin Renvoize (ashimema)
QA Contact: Testopia
URL:
Keywords:
Depends on: 40318
Blocks:
  Show dependency treegraph
 
Reported: 2025-07-18 10:55 UTC by Martin Renvoize (ashimema)
Modified: 2025-07-18 11:32 UTC (History)
1 user (show)

See Also:
GIT URL:
Change sponsored?: ---
Patch complexity: ---
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
Circulation function:


Attachments
Bug 40447: Add comprehensive JSDoc documentation to Cypress plugins (29.90 KB, patch)
2025-07-18 10:55 UTC, Martin Renvoize (ashimema)
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Renvoize (ashimema) 2025-07-18 10:55:16 UTC
We didn't add JSDoc to the new testbuilding tools.. this should help devs get up to speed quicker and aid development environments too.
Comment 1 Martin Renvoize (ashimema) 2025-07-18 10:55:52 UTC
Created attachment 184320 [details] [review]
Bug 40447: Add comprehensive JSDoc documentation to Cypress plugins

This patch adds detailed JSDoc documentation to all Cypress testing
plugin files.

Documentation added to:
- insertData.js: Data insertion utilities with examples
- api-client.js: API wrapper functions with usage patterns
- mockData.js: Schema-based mock data generation
- auth.js: Authentication helper functions
- db.js: Database query utilities
- readYamlFile.js: YAML file reading utilities
- index.js: Main plugin configuration

Each function now includes:
- Complete parameter descriptions with types
- Return value documentation
- Practical usage examples
- Error conditions and handling
- Module-level overviews

This addresses the documentation gap identified during QA review,
hopefully making it easier for future devs to adopt the new framework of
tools.