@webpieces/rules-config 0.4.515 → 0.4.517

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@webpieces/rules-config",
3
- "version": "0.4.515",
3
+ "version": "0.4.517",
4
4
  "description": "Shared webpieces.config.json loader. Single source of truth for validation rule configuration consumed by @webpieces/ai-hook-rules, @webpieces/code-rules, and @webpieces/nx-webpieces-rules.",
5
5
  "type": "commonjs",
6
6
  "main": "./src/index.js",
@@ -77,6 +77,18 @@ if (isAdminWithWriteAccess(user)) {
77
77
  }
78
78
  ```
79
79
 
80
+ ## Test files: do NOT split a `describe`
81
+
82
+ A `describe(...)` block is a CONTAINER, not a unit of logic, so in `*.spec.ts` / `*.test.ts`
83
+ the callback passed to `describe` / `suite` / `context` (including `.only`, `.skip`, `.each`)
84
+ is NOT counted by this rule. Never split a describe block, and never extract a helper, just to
85
+ satisfy a line limit - that invents structure that maps to nothing.
86
+
87
+ What IS still counted in a test file: each `it(...)` / `test(...)` body, the `beforeEach` /
88
+ `beforeAll` / `afterEach` / `afterAll` hooks, and any named or assigned helper function. If one
89
+ of those trips the limit, fix it with the patterns above - a 200-line test case or a 100-line
90
+ setup hook is a real finding.
91
+
80
92
  ## AI Agent Action Steps
81
93
 
82
94
  1. **IDENTIFY** the long method in the error message