opencode-swarm-plugin 0.36.0 → 0.36.1
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/.hive/issues.jsonl +4 -4
- package/.hive/memories.jsonl +274 -1
- package/.turbo/turbo-build.log +4 -4
- package/.turbo/turbo-test.log +307 -307
- package/CHANGELOG.md +71 -0
- package/bin/swarm.ts +234 -179
- package/dist/compaction-hook.d.ts +54 -4
- package/dist/compaction-hook.d.ts.map +1 -1
- package/dist/eval-capture.d.ts +122 -17
- package/dist/eval-capture.d.ts.map +1 -1
- package/dist/index.d.ts +1 -7
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1278 -619
- package/dist/planning-guardrails.d.ts +121 -0
- package/dist/planning-guardrails.d.ts.map +1 -1
- package/dist/plugin.d.ts +9 -9
- package/dist/plugin.d.ts.map +1 -1
- package/dist/plugin.js +1283 -329
- package/dist/schemas/task.d.ts +0 -1
- package/dist/schemas/task.d.ts.map +1 -1
- package/dist/swarm-decompose.d.ts +0 -8
- package/dist/swarm-decompose.d.ts.map +1 -1
- package/dist/swarm-orchestrate.d.ts.map +1 -1
- package/dist/swarm-prompts.d.ts +0 -4
- package/dist/swarm-prompts.d.ts.map +1 -1
- package/dist/swarm-review.d.ts.map +1 -1
- package/dist/swarm.d.ts +0 -6
- package/dist/swarm.d.ts.map +1 -1
- package/evals/README.md +38 -0
- package/evals/coordinator-session.eval.ts +154 -0
- package/evals/fixtures/coordinator-sessions.ts +328 -0
- package/evals/lib/data-loader.ts +69 -0
- package/evals/scorers/coordinator-discipline.evalite-test.ts +536 -0
- package/evals/scorers/coordinator-discipline.ts +315 -0
- package/evals/scorers/index.ts +12 -0
- package/examples/plugin-wrapper-template.ts +303 -4
- package/package.json +2 -2
- package/src/compaction-hook.test.ts +8 -1
- package/src/compaction-hook.ts +31 -21
- package/src/eval-capture.test.ts +390 -0
- package/src/eval-capture.ts +163 -4
- package/src/index.ts +68 -1
- package/src/planning-guardrails.test.ts +387 -2
- package/src/planning-guardrails.ts +289 -0
- package/src/plugin.ts +10 -10
- package/src/swarm-decompose.ts +20 -0
- package/src/swarm-orchestrate.ts +44 -0
- package/src/swarm-prompts.ts +20 -0
- package/src/swarm-review.ts +41 -0
package/.turbo/turbo-test.log
CHANGED
|
@@ -3,183 +3,183 @@ bun test v1.3.4 (5eb2145b)
|
|
|
3
3
|
|
|
4
4
|
src/structured.test.ts:
|
|
5
5
|
(pass) extractJsonFromText > Strategy 1: Direct parse > extracts clean JSON directly [0.13ms]
|
|
6
|
-
(pass) extractJsonFromText > Strategy 1: Direct parse > handles nested objects [0.
|
|
7
|
-
(pass) extractJsonFromText > Strategy 1: Direct parse > handles arrays [0.
|
|
6
|
+
(pass) extractJsonFromText > Strategy 1: Direct parse > handles nested objects [0.07ms]
|
|
7
|
+
(pass) extractJsonFromText > Strategy 1: Direct parse > handles arrays [0.01ms]
|
|
8
8
|
(pass) extractJsonFromText > Strategy 1: Direct parse > handles complex nested structures [0.02ms]
|
|
9
|
-
(pass) extractJsonFromText > Strategy 2: JSON code block > extracts JSON from ```json code block [0.
|
|
10
|
-
(pass) extractJsonFromText > Strategy 2: JSON code block > handles code block with surrounding text [0.
|
|
9
|
+
(pass) extractJsonFromText > Strategy 2: JSON code block > extracts JSON from ```json code block [0.13ms]
|
|
10
|
+
(pass) extractJsonFromText > Strategy 2: JSON code block > handles code block with surrounding text [0.06ms]
|
|
11
11
|
(pass) extractJsonFromText > Strategy 2: JSON code block > handles multiline JSON in code block [0.02ms]
|
|
12
|
-
(pass) extractJsonFromText > Strategy 3: Generic code block > extracts JSON from unlabeled code block [0.
|
|
12
|
+
(pass) extractJsonFromText > Strategy 3: Generic code block > extracts JSON from unlabeled code block [0.02ms]
|
|
13
13
|
(pass) extractJsonFromText > Strategy 3: Generic code block > prefers json-labeled block over generic block [0.02ms]
|
|
14
14
|
(pass) extractJsonFromText > Strategy 4: Brace matching for objects > extracts JSON with surrounding text [0.01ms]
|
|
15
15
|
(pass) extractJsonFromText > Strategy 4: Brace matching for objects > extracts first balanced object when multiple present [0.05ms]
|
|
16
16
|
(pass) extractJsonFromText > Strategy 4: Brace matching for objects > handles deeply nested objects [0.02ms]
|
|
17
|
-
(pass) extractJsonFromText > Strategy 4: Brace matching for objects > handles strings containing braces
|
|
18
|
-
(pass) extractJsonFromText > Strategy 4: Brace matching for objects > handles escaped quotes in strings [0.
|
|
17
|
+
(pass) extractJsonFromText > Strategy 4: Brace matching for objects > handles strings containing braces
|
|
18
|
+
(pass) extractJsonFromText > Strategy 4: Brace matching for objects > handles escaped quotes in strings [0.03ms]
|
|
19
19
|
(pass) extractJsonFromText > Strategy 5: Bracket matching for arrays > extracts arrays with surrounding text [0.01ms]
|
|
20
|
-
(pass) extractJsonFromText > Strategy 5: Bracket matching for arrays > handles nested arrays
|
|
21
|
-
(pass) extractJsonFromText > Strategy 5: Bracket matching for arrays > prefers object matching over array when both present
|
|
20
|
+
(pass) extractJsonFromText > Strategy 5: Bracket matching for arrays > handles nested arrays [0.01ms]
|
|
21
|
+
(pass) extractJsonFromText > Strategy 5: Bracket matching for arrays > prefers object matching over array when both present [0.01ms]
|
|
22
22
|
(pass) extractJsonFromText > Strategy 6: JSON repair > fixes single quotes in keys (limited support) [0.10ms]
|
|
23
|
-
(pass) extractJsonFromText > Strategy 6: JSON repair > fixes trailing commas in objects [0.
|
|
23
|
+
(pass) extractJsonFromText > Strategy 6: JSON repair > fixes trailing commas in objects [0.03ms]
|
|
24
24
|
(pass) extractJsonFromText > Strategy 6: JSON repair > fixes trailing commas in arrays [0.02ms]
|
|
25
25
|
(pass) extractJsonFromText > Strategy 6: JSON repair > fixes multiple trailing commas [0.02ms]
|
|
26
|
-
(pass) extractJsonFromText > Error cases > throws JsonExtractionError for invalid JSON [0.
|
|
27
|
-
(pass) extractJsonFromText > Error cases > throws JsonExtractionError for empty input [0.
|
|
28
|
-
(pass) extractJsonFromText > Error cases > throws JsonExtractionError for unbalanced braces [0.
|
|
29
|
-
(pass) extractJsonFromText > Error cases > throws JsonExtractionError for malformed JSON [0.
|
|
30
|
-
(pass) extractJsonFromText > Error cases > includes attempted strategies in error [0.
|
|
31
|
-
(pass) extractJsonFromText > Error cases > returns null for deeply nested input exceeding MAX_BRACE_DEPTH [0.
|
|
32
|
-
(pass) formatZodErrors > formats single error with path [0.
|
|
33
|
-
(pass) formatZodErrors > formats multiple errors [0.
|
|
34
|
-
(pass) formatZodErrors > formats nested path [0.
|
|
35
|
-
(pass) formatZodErrors > formats error without path [0.
|
|
36
|
-
(pass) getSchemaByName > returns EvaluationSchema for 'evaluation' [0.
|
|
26
|
+
(pass) extractJsonFromText > Error cases > throws JsonExtractionError for invalid JSON [0.02ms]
|
|
27
|
+
(pass) extractJsonFromText > Error cases > throws JsonExtractionError for empty input [0.05ms]
|
|
28
|
+
(pass) extractJsonFromText > Error cases > throws JsonExtractionError for unbalanced braces [0.03ms]
|
|
29
|
+
(pass) extractJsonFromText > Error cases > throws JsonExtractionError for malformed JSON [0.01ms]
|
|
30
|
+
(pass) extractJsonFromText > Error cases > includes attempted strategies in error [0.03ms]
|
|
31
|
+
(pass) extractJsonFromText > Error cases > returns null for deeply nested input exceeding MAX_BRACE_DEPTH [0.04ms]
|
|
32
|
+
(pass) formatZodErrors > formats single error with path [0.80ms]
|
|
33
|
+
(pass) formatZodErrors > formats multiple errors [0.27ms]
|
|
34
|
+
(pass) formatZodErrors > formats nested path [0.15ms]
|
|
35
|
+
(pass) formatZodErrors > formats error without path [0.03ms]
|
|
36
|
+
(pass) getSchemaByName > returns EvaluationSchema for 'evaluation' [0.04ms]
|
|
37
37
|
(pass) getSchemaByName > returns TaskDecompositionSchema for 'task_decomposition'
|
|
38
38
|
(pass) getSchemaByName > returns CellTreeSchema for 'cell_tree'
|
|
39
39
|
(pass) getSchemaByName > throws error for unknown schema name [0.01ms]
|
|
40
|
-
(pass) getSchemaByName > error message lists available schemas [0.
|
|
41
|
-
(pass) StructuredValidationError > formats error bullets from ZodError [0.
|
|
42
|
-
(pass) StructuredValidationError > handles null ZodError [0.
|
|
43
|
-
(pass) StructuredValidationError > includes extraction method when provided
|
|
44
|
-
(pass) structured_extract_json > returns success for valid JSON [0.
|
|
45
|
-
(pass) structured_extract_json > returns success for JSON in code block [0.
|
|
46
|
-
(pass) structured_extract_json > returns error for invalid JSON [0.
|
|
47
|
-
(pass) structured_extract_json > includes raw input preview in error [0.
|
|
48
|
-
(pass) structured_validate > evaluation schema > validates correct evaluation [0.
|
|
49
|
-
(pass) structured_validate > evaluation schema > returns error for invalid evaluation [0.
|
|
40
|
+
(pass) getSchemaByName > error message lists available schemas [0.02ms]
|
|
41
|
+
(pass) StructuredValidationError > formats error bullets from ZodError [0.07ms]
|
|
42
|
+
(pass) StructuredValidationError > handles null ZodError [0.08ms]
|
|
43
|
+
(pass) StructuredValidationError > includes extraction method when provided [0.02ms]
|
|
44
|
+
(pass) structured_extract_json > returns success for valid JSON [0.05ms]
|
|
45
|
+
(pass) structured_extract_json > returns success for JSON in code block [0.11ms]
|
|
46
|
+
(pass) structured_extract_json > returns error for invalid JSON [0.02ms]
|
|
47
|
+
(pass) structured_extract_json > includes raw input preview in error [0.07ms]
|
|
48
|
+
(pass) structured_validate > evaluation schema > validates correct evaluation [0.51ms]
|
|
49
|
+
(pass) structured_validate > evaluation schema > returns error for invalid evaluation [0.11ms]
|
|
50
50
|
(pass) structured_validate > evaluation schema > handles empty response [0.02ms]
|
|
51
|
-
(pass) structured_validate > evaluation schema > handles whitespace-only response [0.
|
|
52
|
-
(pass) structured_validate > task_decomposition schema > validates correct decomposition [0.
|
|
53
|
-
(pass) structured_validate > cell_tree schema > validates correct bead tree [0.
|
|
54
|
-
(pass) structured_validate > extracts JSON from markdown before validation [0.
|
|
55
|
-
(pass) structured_validate > includes retry hint when attempts < max_retries [0.
|
|
51
|
+
(pass) structured_validate > evaluation schema > handles whitespace-only response [0.06ms]
|
|
52
|
+
(pass) structured_validate > task_decomposition schema > validates correct decomposition [0.55ms]
|
|
53
|
+
(pass) structured_validate > cell_tree schema > validates correct bead tree [0.34ms]
|
|
54
|
+
(pass) structured_validate > extracts JSON from markdown before validation [0.04ms]
|
|
55
|
+
(pass) structured_validate > includes retry hint when attempts < max_retries [0.11ms]
|
|
56
56
|
(pass) structured_parse_evaluation > parses valid evaluation [0.14ms]
|
|
57
|
-
(pass) structured_parse_evaluation > identifies failed criteria in summary [0.
|
|
58
|
-
(pass) structured_parse_evaluation > returns error for malformed JSON [0.
|
|
59
|
-
(pass) structured_parse_evaluation > returns error for invalid evaluation schema [0.
|
|
57
|
+
(pass) structured_parse_evaluation > identifies failed criteria in summary [0.04ms]
|
|
58
|
+
(pass) structured_parse_evaluation > returns error for malformed JSON [0.10ms]
|
|
59
|
+
(pass) structured_parse_evaluation > returns error for invalid evaluation schema [0.02ms]
|
|
60
60
|
(pass) structured_parse_evaluation > includes expected shape in error feedback [0.06ms]
|
|
61
|
-
(pass) structured_parse_decomposition > parses valid decomposition [0.
|
|
62
|
-
(pass) structured_parse_decomposition > includes effort breakdown in summary
|
|
63
|
-
(pass) structured_parse_decomposition > handles dependencies in summary [0.
|
|
64
|
-
(pass) structured_parse_decomposition > deduplicates files in summary [0.
|
|
65
|
-
(pass) structured_parse_decomposition > returns error for invalid decomposition [0.
|
|
66
|
-
(pass) structured_parse_cell_tree > parses valid bead tree [0.
|
|
67
|
-
(pass) structured_parse_cell_tree > calculates complexity total [0.
|
|
68
|
-
(pass) structured_parse_cell_tree > lists unique files [0.
|
|
69
|
-
(pass) structured_parse_cell_tree > returns error for invalid bead tree [0.
|
|
70
|
-
(pass) structured_parse_cell_tree > includes expected shape in error [0.
|
|
71
|
-
(pass) Edge cases > handles JSON with unicode characters [0.
|
|
72
|
-
(pass) Edge cases > handles very long strings in JSON [0.
|
|
61
|
+
(pass) structured_parse_decomposition > parses valid decomposition [0.28ms]
|
|
62
|
+
(pass) structured_parse_decomposition > includes effort breakdown in summary [0.02ms]
|
|
63
|
+
(pass) structured_parse_decomposition > handles dependencies in summary [0.19ms]
|
|
64
|
+
(pass) structured_parse_decomposition > deduplicates files in summary [0.06ms]
|
|
65
|
+
(pass) structured_parse_decomposition > returns error for invalid decomposition [0.09ms]
|
|
66
|
+
(pass) structured_parse_cell_tree > parses valid bead tree [0.14ms]
|
|
67
|
+
(pass) structured_parse_cell_tree > calculates complexity total [0.03ms]
|
|
68
|
+
(pass) structured_parse_cell_tree > lists unique files [0.07ms]
|
|
69
|
+
(pass) structured_parse_cell_tree > returns error for invalid bead tree [0.07ms]
|
|
70
|
+
(pass) structured_parse_cell_tree > includes expected shape in error [0.08ms]
|
|
71
|
+
(pass) Edge cases > handles JSON with unicode characters [0.02ms]
|
|
72
|
+
(pass) Edge cases > handles very long strings in JSON [0.03ms]
|
|
73
73
|
(pass) Edge cases > handles JSON with null values [0.02ms]
|
|
74
|
-
(pass) Edge cases > handles JSON with boolean values
|
|
75
|
-
(pass) Edge cases > handles JSON with number types
|
|
74
|
+
(pass) Edge cases > handles JSON with boolean values
|
|
75
|
+
(pass) Edge cases > handles JSON with number types
|
|
76
76
|
(pass) Edge cases > handles mixed content markdown with multiple code blocks [0.01ms]
|
|
77
|
-
(pass) Edge cases > handles JSON with escaped characters [0.
|
|
77
|
+
(pass) Edge cases > handles JSON with escaped characters [0.01ms]
|
|
78
78
|
|
|
79
79
|
src/mandate-storage.test.ts:
|
|
80
|
-
(pass) InMemoryMandateStorage > Entry operations > should store and retrieve mandate entry [0.
|
|
81
|
-
(pass) InMemoryMandateStorage > Entry operations > should return null for non-existent mandate [0.
|
|
82
|
-
(pass) InMemoryMandateStorage > Entry operations > should find mandates by query [0.
|
|
80
|
+
(pass) InMemoryMandateStorage > Entry operations > should store and retrieve mandate entry [0.16ms]
|
|
81
|
+
(pass) InMemoryMandateStorage > Entry operations > should return null for non-existent mandate [0.03ms]
|
|
82
|
+
(pass) InMemoryMandateStorage > Entry operations > should find mandates by query [0.17ms]
|
|
83
83
|
(pass) InMemoryMandateStorage > Entry operations > should list all mandates [0.06ms]
|
|
84
|
-
(pass) InMemoryMandateStorage > Entry operations > should filter mandates by status [0.
|
|
85
|
-
(pass) InMemoryMandateStorage > Entry operations > should filter mandates by content_type [0.
|
|
84
|
+
(pass) InMemoryMandateStorage > Entry operations > should filter mandates by status [0.03ms]
|
|
85
|
+
(pass) InMemoryMandateStorage > Entry operations > should filter mandates by content_type [0.07ms]
|
|
86
86
|
(pass) InMemoryMandateStorage > Entry operations > should update mandate entry [0.06ms]
|
|
87
|
-
(pass) InMemoryMandateStorage > Entry operations > should throw when updating non-existent mandate [0.
|
|
88
|
-
(pass) InMemoryMandateStorage > Vote operations > should cast vote and verify storage [0.
|
|
89
|
-
(pass) InMemoryMandateStorage > Vote operations > should prevent duplicate votes from same agent [0.
|
|
90
|
-
(pass) InMemoryMandateStorage > Vote operations > should check if agent has voted
|
|
91
|
-
(pass) InMemoryMandateStorage > Vote operations > should get all votes for a mandate [0.
|
|
92
|
-
(pass) InMemoryMandateStorage > Score calculation with decay > should calculate score with no votes [0.
|
|
93
|
-
(pass) InMemoryMandateStorage > Score calculation with decay > should calculate score with recent upvotes [0.
|
|
94
|
-
(pass) InMemoryMandateStorage > Score calculation with decay > should calculate score with mixed votes [0.
|
|
95
|
-
(pass) InMemoryMandateStorage > Score calculation with decay > should apply decay to old votes [0.
|
|
96
|
-
(pass) InMemoryMandateStorage > Score calculation with decay > should handle vote weights [0.
|
|
97
|
-
(pass) InMemoryMandateStorage > Status updates based on score > should transition to mandate status with high score [0.
|
|
98
|
-
(pass) InMemoryMandateStorage > Status updates based on score > should transition to established status [0.
|
|
99
|
-
(pass) InMemoryMandateStorage > Status updates based on score > should transition to rejected status [0.
|
|
100
|
-
(pass) InMemoryMandateStorage > Status updates based on score > should batch update all mandates [0.
|
|
101
|
-
(pass) InMemoryMandateStorage > Factory > should create in-memory storage [0.
|
|
102
|
-
(pass) InMemoryMandateStorage > Factory > should throw on unknown backend
|
|
87
|
+
(pass) InMemoryMandateStorage > Entry operations > should throw when updating non-existent mandate [0.08ms]
|
|
88
|
+
(pass) InMemoryMandateStorage > Vote operations > should cast vote and verify storage [0.09ms]
|
|
89
|
+
(pass) InMemoryMandateStorage > Vote operations > should prevent duplicate votes from same agent [0.06ms]
|
|
90
|
+
(pass) InMemoryMandateStorage > Vote operations > should check if agent has voted [0.04ms]
|
|
91
|
+
(pass) InMemoryMandateStorage > Vote operations > should get all votes for a mandate [0.03ms]
|
|
92
|
+
(pass) InMemoryMandateStorage > Score calculation with decay > should calculate score with no votes [0.12ms]
|
|
93
|
+
(pass) InMemoryMandateStorage > Score calculation with decay > should calculate score with recent upvotes [0.07ms]
|
|
94
|
+
(pass) InMemoryMandateStorage > Score calculation with decay > should calculate score with mixed votes [0.08ms]
|
|
95
|
+
(pass) InMemoryMandateStorage > Score calculation with decay > should apply decay to old votes [0.52ms]
|
|
96
|
+
(pass) InMemoryMandateStorage > Score calculation with decay > should handle vote weights [0.02ms]
|
|
97
|
+
(pass) InMemoryMandateStorage > Status updates based on score > should transition to mandate status with high score [0.29ms]
|
|
98
|
+
(pass) InMemoryMandateStorage > Status updates based on score > should transition to established status [0.08ms]
|
|
99
|
+
(pass) InMemoryMandateStorage > Status updates based on score > should transition to rejected status [0.05ms]
|
|
100
|
+
(pass) InMemoryMandateStorage > Status updates based on score > should batch update all mandates [0.12ms]
|
|
101
|
+
(pass) InMemoryMandateStorage > Factory > should create in-memory storage [0.05ms]
|
|
102
|
+
(pass) InMemoryMandateStorage > Factory > should throw on unknown backend [0.01ms]
|
|
103
103
|
|
|
104
104
|
src/skills.test.ts:
|
|
105
|
-
(pass) parseFrontmatter > parses valid frontmatter with all fields [1.
|
|
106
|
-
(pass) parseFrontmatter > parses minimal frontmatter with only required fields [0.
|
|
107
|
-
(pass) parseFrontmatter > returns null for missing name value
|
|
105
|
+
(pass) parseFrontmatter > parses valid frontmatter with all fields [1.53ms]
|
|
106
|
+
(pass) parseFrontmatter > parses minimal frontmatter with only required fields [0.09ms]
|
|
107
|
+
(pass) parseFrontmatter > returns null for missing name value
|
|
108
108
|
(pass) parseFrontmatter > returns empty result for content without frontmatter
|
|
109
|
-
(pass) parseFrontmatter > returns empty result for empty content
|
|
110
|
-
(pass) parseFrontmatter > handles frontmatter with extra fields [0.
|
|
111
|
-
(pass) parseFrontmatter > handles multiline description [0.
|
|
112
|
-
[skills] Failed to load /Users/joel/Code/joelhooks/opencode-swarm-plugin/packages/opencode-swarm-plugin/.test-skills-
|
|
109
|
+
(pass) parseFrontmatter > returns empty result for empty content
|
|
110
|
+
(pass) parseFrontmatter > handles frontmatter with extra fields [0.17ms]
|
|
111
|
+
(pass) parseFrontmatter > handles multiline description [0.04ms]
|
|
112
|
+
[skills] Failed to load /Users/joel/Code/joelhooks/opencode-swarm-plugin/packages/opencode-swarm-plugin/.test-skills-1766613874554-654sz3/.opencode/skills/invalid-skill/SKILL.md: Skill at /Users/joel/Code/joelhooks/opencode-swarm-plugin/packages/opencode-swarm-plugin/.test-skills-1766613874554-654sz3/.opencode/skills/invalid-skill/SKILL.md missing required 'name' field
|
|
113
113
|
[skills] Failed to load /Users/joel/.config/opencode/skills/ai-optimized-content/SKILL.md: Skill at /Users/joel/.config/opencode/skills/ai-optimized-content/SKILL.md missing required 'name' field
|
|
114
|
-
(pass) discoverSkills > discovers skills in project directory [
|
|
115
|
-
[skills] Failed to load /Users/joel/Code/joelhooks/opencode-swarm-plugin/packages/opencode-swarm-plugin/.test-skills-
|
|
114
|
+
(pass) discoverSkills > discovers skills in project directory [22.29ms]
|
|
115
|
+
[skills] Failed to load /Users/joel/Code/joelhooks/opencode-swarm-plugin/packages/opencode-swarm-plugin/.test-skills-1766613874554-654sz3/.opencode/skills/invalid-skill/SKILL.md: Skill at /Users/joel/Code/joelhooks/opencode-swarm-plugin/packages/opencode-swarm-plugin/.test-skills-1766613874554-654sz3/.opencode/skills/invalid-skill/SKILL.md missing required 'name' field
|
|
116
116
|
[skills] Failed to load /Users/joel/.config/opencode/skills/ai-optimized-content/SKILL.md: Skill at /Users/joel/.config/opencode/skills/ai-optimized-content/SKILL.md missing required 'name' field
|
|
117
|
-
(pass) discoverSkills > skips skills with invalid frontmatter [
|
|
118
|
-
[skills] Failed to load /Users/joel/Code/joelhooks/opencode-swarm-plugin/packages/opencode-swarm-plugin/.test-skills-
|
|
117
|
+
(pass) discoverSkills > skips skills with invalid frontmatter [14.89ms]
|
|
118
|
+
[skills] Failed to load /Users/joel/Code/joelhooks/opencode-swarm-plugin/packages/opencode-swarm-plugin/.test-skills-1766613874554-654sz3/.opencode/skills/invalid-skill/SKILL.md: Skill at /Users/joel/Code/joelhooks/opencode-swarm-plugin/packages/opencode-swarm-plugin/.test-skills-1766613874554-654sz3/.opencode/skills/invalid-skill/SKILL.md missing required 'name' field
|
|
119
119
|
[skills] Failed to load /Users/joel/.config/opencode/skills/ai-optimized-content/SKILL.md: Skill at /Users/joel/.config/opencode/skills/ai-optimized-content/SKILL.md missing required 'name' field
|
|
120
|
-
(pass) discoverSkills > caches discovered skills [
|
|
121
|
-
[skills] Failed to load /Users/joel/Code/joelhooks/opencode-swarm-plugin/packages/opencode-swarm-plugin/.test-skills-
|
|
120
|
+
(pass) discoverSkills > caches discovered skills [14.74ms]
|
|
121
|
+
[skills] Failed to load /Users/joel/Code/joelhooks/opencode-swarm-plugin/packages/opencode-swarm-plugin/.test-skills-1766613874554-654sz3/.opencode/skills/invalid-skill/SKILL.md: Skill at /Users/joel/Code/joelhooks/opencode-swarm-plugin/packages/opencode-swarm-plugin/.test-skills-1766613874554-654sz3/.opencode/skills/invalid-skill/SKILL.md missing required 'name' field
|
|
122
122
|
[skills] Failed to load /Users/joel/.config/opencode/skills/ai-optimized-content/SKILL.md: Skill at /Users/joel/.config/opencode/skills/ai-optimized-content/SKILL.md missing required 'name' field
|
|
123
|
-
[skills] Failed to load /Users/joel/Code/joelhooks/opencode-swarm-plugin/packages/opencode-swarm-plugin/.test-skills-
|
|
123
|
+
[skills] Failed to load /Users/joel/Code/joelhooks/opencode-swarm-plugin/packages/opencode-swarm-plugin/.test-skills-1766613874554-654sz3/.opencode/skills/invalid-skill/SKILL.md: Skill at /Users/joel/Code/joelhooks/opencode-swarm-plugin/packages/opencode-swarm-plugin/.test-skills-1766613874554-654sz3/.opencode/skills/invalid-skill/SKILL.md missing required 'name' field
|
|
124
124
|
[skills] Failed to load /Users/joel/.config/opencode/skills/ai-optimized-content/SKILL.md: Skill at /Users/joel/.config/opencode/skills/ai-optimized-content/SKILL.md missing required 'name' field
|
|
125
|
-
(pass) discoverSkills > invalidates cache when requested [
|
|
126
|
-
[skills] Failed to load /Users/joel/Code/joelhooks/opencode-swarm-plugin/packages/opencode-swarm-plugin/.test-skills-
|
|
125
|
+
(pass) discoverSkills > invalidates cache when requested [13.21ms]
|
|
126
|
+
[skills] Failed to load /Users/joel/Code/joelhooks/opencode-swarm-plugin/packages/opencode-swarm-plugin/.test-skills-1766613874554-654sz3/.opencode/skills/invalid-skill/SKILL.md: Skill at /Users/joel/Code/joelhooks/opencode-swarm-plugin/packages/opencode-swarm-plugin/.test-skills-1766613874554-654sz3/.opencode/skills/invalid-skill/SKILL.md missing required 'name' field
|
|
127
127
|
[skills] Failed to load /Users/joel/.config/opencode/skills/ai-optimized-content/SKILL.md: Skill at /Users/joel/.config/opencode/skills/ai-optimized-content/SKILL.md missing required 'name' field
|
|
128
|
-
(pass) getSkill > returns skill by exact name [
|
|
129
|
-
[skills] Failed to load /Users/joel/Code/joelhooks/opencode-swarm-plugin/packages/opencode-swarm-plugin/.test-skills-
|
|
128
|
+
(pass) getSkill > returns skill by exact name [8.16ms]
|
|
129
|
+
[skills] Failed to load /Users/joel/Code/joelhooks/opencode-swarm-plugin/packages/opencode-swarm-plugin/.test-skills-1766613874554-654sz3/.opencode/skills/invalid-skill/SKILL.md: Skill at /Users/joel/Code/joelhooks/opencode-swarm-plugin/packages/opencode-swarm-plugin/.test-skills-1766613874554-654sz3/.opencode/skills/invalid-skill/SKILL.md missing required 'name' field
|
|
130
130
|
[skills] Failed to load /Users/joel/.config/opencode/skills/ai-optimized-content/SKILL.md: Skill at /Users/joel/.config/opencode/skills/ai-optimized-content/SKILL.md missing required 'name' field
|
|
131
|
-
(pass) getSkill > returns null for non-existent skill [
|
|
132
|
-
[skills] Failed to load /Users/joel/Code/joelhooks/opencode-swarm-plugin/packages/opencode-swarm-plugin/.test-skills-
|
|
131
|
+
(pass) getSkill > returns null for non-existent skill [8.22ms]
|
|
132
|
+
[skills] Failed to load /Users/joel/Code/joelhooks/opencode-swarm-plugin/packages/opencode-swarm-plugin/.test-skills-1766613874554-654sz3/.opencode/skills/invalid-skill/SKILL.md: Skill at /Users/joel/Code/joelhooks/opencode-swarm-plugin/packages/opencode-swarm-plugin/.test-skills-1766613874554-654sz3/.opencode/skills/invalid-skill/SKILL.md missing required 'name' field
|
|
133
133
|
[skills] Failed to load /Users/joel/.config/opencode/skills/ai-optimized-content/SKILL.md: Skill at /Users/joel/.config/opencode/skills/ai-optimized-content/SKILL.md missing required 'name' field
|
|
134
|
-
(pass) getSkill > returns null for empty name [
|
|
135
|
-
[skills] Failed to load /Users/joel/Code/joelhooks/opencode-swarm-plugin/packages/opencode-swarm-plugin/.test-skills-
|
|
134
|
+
(pass) getSkill > returns null for empty name [5.71ms]
|
|
135
|
+
[skills] Failed to load /Users/joel/Code/joelhooks/opencode-swarm-plugin/packages/opencode-swarm-plugin/.test-skills-1766613874554-654sz3/.opencode/skills/invalid-skill/SKILL.md: Skill at /Users/joel/Code/joelhooks/opencode-swarm-plugin/packages/opencode-swarm-plugin/.test-skills-1766613874554-654sz3/.opencode/skills/invalid-skill/SKILL.md missing required 'name' field
|
|
136
136
|
[skills] Failed to load /Users/joel/.config/opencode/skills/ai-optimized-content/SKILL.md: Skill at /Users/joel/.config/opencode/skills/ai-optimized-content/SKILL.md missing required 'name' field
|
|
137
|
-
(pass) listSkills > returns skill refs with name, description, and path [
|
|
138
|
-
(pass) path traversal protection > detects basic path traversal attempts [0.
|
|
139
|
-
(pass) path traversal protection > allows valid relative paths [0.
|
|
137
|
+
(pass) listSkills > returns skill refs with name, description, and path [6.25ms]
|
|
138
|
+
(pass) path traversal protection > detects basic path traversal attempts [0.04ms]
|
|
139
|
+
(pass) path traversal protection > allows valid relative paths [0.04ms]
|
|
140
140
|
(pass) path traversal protection > resolve + relative check catches encoded traversal [0.02ms]
|
|
141
|
-
(pass) ES module compatibility > import.meta.url is available [0.
|
|
141
|
+
(pass) ES module compatibility > import.meta.url is available [0.06ms]
|
|
142
142
|
(pass) ES module compatibility > can construct path from import.meta.url [0.02ms]
|
|
143
|
-
(pass) validateCSOCompliance > description validation > passes for CSO-compliant description with 'Use when' [0.
|
|
144
|
-
(pass) validateCSOCompliance > description validation > warns when missing 'Use when...' pattern
|
|
145
|
-
(pass) validateCSOCompliance > description validation > warns for first-person voice
|
|
146
|
-
(pass) validateCSOCompliance > description validation > warns for second-person voice [0.
|
|
147
|
-
(pass) validateCSOCompliance > description validation > rejects description > 1024 chars [0.
|
|
148
|
-
(pass) validateCSOCompliance > description validation > suggests improvement for description > 500 chars
|
|
149
|
-
(pass) validateCSOCompliance > description validation > accepts description < 500 chars with no length warnings
|
|
150
|
-
(pass) validateCSOCompliance > name validation > accepts gerund-based names
|
|
143
|
+
(pass) validateCSOCompliance > description validation > passes for CSO-compliant description with 'Use when' [0.08ms]
|
|
144
|
+
(pass) validateCSOCompliance > description validation > warns when missing 'Use when...' pattern
|
|
145
|
+
(pass) validateCSOCompliance > description validation > warns for first-person voice
|
|
146
|
+
(pass) validateCSOCompliance > description validation > warns for second-person voice [0.09ms]
|
|
147
|
+
(pass) validateCSOCompliance > description validation > rejects description > 1024 chars [0.03ms]
|
|
148
|
+
(pass) validateCSOCompliance > description validation > suggests improvement for description > 500 chars
|
|
149
|
+
(pass) validateCSOCompliance > description validation > accepts description < 500 chars with no length warnings
|
|
150
|
+
(pass) validateCSOCompliance > name validation > accepts gerund-based names [0.01ms]
|
|
151
151
|
(pass) validateCSOCompliance > name validation > accepts verb-first names
|
|
152
|
-
(pass) validateCSOCompliance > name validation > accepts action verbs [0.
|
|
153
|
-
(pass) validateCSOCompliance > name validation > suggests verb-first for noun-first names [0.
|
|
154
|
-
(pass) validateCSOCompliance > name validation > warns for name > 64 chars
|
|
155
|
-
(pass) validateCSOCompliance > name validation > warns for invalid name format [0.
|
|
152
|
+
(pass) validateCSOCompliance > name validation > accepts action verbs [0.03ms]
|
|
153
|
+
(pass) validateCSOCompliance > name validation > suggests verb-first for noun-first names [0.01ms]
|
|
154
|
+
(pass) validateCSOCompliance > name validation > warns for name > 64 chars
|
|
155
|
+
(pass) validateCSOCompliance > name validation > warns for invalid name format [0.02ms]
|
|
156
156
|
(pass) validateCSOCompliance > comprehensive examples > perfect CSO compliance
|
|
157
|
-
(pass) validateCSOCompliance > comprehensive examples > multiple critical issues
|
|
158
|
-
[skills] Failed to load /Users/joel/Code/joelhooks/opencode-swarm-plugin/packages/opencode-swarm-plugin/.test-skills-
|
|
157
|
+
(pass) validateCSOCompliance > comprehensive examples > multiple critical issues [0.02ms]
|
|
158
|
+
[skills] Failed to load /Users/joel/Code/joelhooks/opencode-swarm-plugin/packages/opencode-swarm-plugin/.test-skills-1766613874554-654sz3/.opencode/skills/invalid-skill/SKILL.md: Skill at /Users/joel/Code/joelhooks/opencode-swarm-plugin/packages/opencode-swarm-plugin/.test-skills-1766613874554-654sz3/.opencode/skills/invalid-skill/SKILL.md missing required 'name' field
|
|
159
159
|
[skills] Failed to load /Users/joel/.config/opencode/skills/ai-optimized-content/SKILL.md: Skill at /Users/joel/.config/opencode/skills/ai-optimized-content/SKILL.md missing required 'name' field
|
|
160
|
-
(pass) deprecation warnings > listSkills emits deprecation warning [2.
|
|
161
|
-
[skills] Failed to load /Users/joel/Code/joelhooks/opencode-swarm-plugin/packages/opencode-swarm-plugin/.test-skills-
|
|
160
|
+
(pass) deprecation warnings > listSkills emits deprecation warning [2.93ms]
|
|
161
|
+
[skills] Failed to load /Users/joel/Code/joelhooks/opencode-swarm-plugin/packages/opencode-swarm-plugin/.test-skills-1766613874554-654sz3/.opencode/skills/invalid-skill/SKILL.md: Skill at /Users/joel/Code/joelhooks/opencode-swarm-plugin/packages/opencode-swarm-plugin/.test-skills-1766613874554-654sz3/.opencode/skills/invalid-skill/SKILL.md missing required 'name' field
|
|
162
162
|
[skills] Failed to load /Users/joel/.config/opencode/skills/ai-optimized-content/SKILL.md: Skill at /Users/joel/.config/opencode/skills/ai-optimized-content/SKILL.md missing required 'name' field
|
|
163
|
-
(pass) deprecation warnings > getSkill does NOT emit deprecation warning (internal function) [
|
|
163
|
+
(pass) deprecation warnings > getSkill does NOT emit deprecation warning (internal function) [3.50ms]
|
|
164
164
|
[skills] Failed to load /Users/joel/.config/opencode/skills/ai-optimized-content/SKILL.md: Skill at /Users/joel/.config/opencode/skills/ai-optimized-content/SKILL.md missing required 'name' field
|
|
165
|
-
(pass) edge cases > handles non-existent skills directory gracefully [1.
|
|
165
|
+
(pass) edge cases > handles non-existent skills directory gracefully [1.07ms]
|
|
166
166
|
[skills] Failed to load /Users/joel/.config/opencode/skills/ai-optimized-content/SKILL.md: Skill at /Users/joel/.config/opencode/skills/ai-optimized-content/SKILL.md missing required 'name' field
|
|
167
|
-
(pass) edge cases > handles empty skills directory [1.
|
|
167
|
+
(pass) edge cases > handles empty skills directory [1.52ms]
|
|
168
168
|
[skills] Failed to load /Users/joel/.config/opencode/skills/ai-optimized-content/SKILL.md: Skill at /Users/joel/.config/opencode/skills/ai-optimized-content/SKILL.md missing required 'name' field
|
|
169
|
-
(pass) edge cases > handles skill directory without SKILL.md [1.
|
|
169
|
+
(pass) edge cases > handles skill directory without SKILL.md [1.58ms]
|
|
170
170
|
|
|
171
171
|
src/anti-patterns.test.ts:
|
|
172
172
|
(pass) PatternKindSchema > validates 'pattern' kind
|
|
173
|
-
(pass) PatternKindSchema > validates 'anti_pattern' kind [0.
|
|
174
|
-
(pass) PatternKindSchema > rejects invalid kind [0.
|
|
175
|
-
(pass) DecompositionPatternSchema > validates a complete valid pattern [0.
|
|
176
|
-
(pass) DecompositionPatternSchema > validates a valid anti-pattern [0.
|
|
177
|
-
(pass) DecompositionPatternSchema > applies default values for optional fields [0.
|
|
173
|
+
(pass) PatternKindSchema > validates 'anti_pattern' kind [0.07ms]
|
|
174
|
+
(pass) PatternKindSchema > rejects invalid kind [0.11ms]
|
|
175
|
+
(pass) DecompositionPatternSchema > validates a complete valid pattern [0.36ms]
|
|
176
|
+
(pass) DecompositionPatternSchema > validates a valid anti-pattern [0.04ms]
|
|
177
|
+
(pass) DecompositionPatternSchema > applies default values for optional fields [0.03ms]
|
|
178
178
|
(pass) DecompositionPatternSchema > rejects negative success_count [0.07ms]
|
|
179
|
-
(pass) DecompositionPatternSchema > rejects negative failure_count [0.
|
|
179
|
+
(pass) DecompositionPatternSchema > rejects negative failure_count [0.04ms]
|
|
180
180
|
(pass) DecompositionPatternSchema > rejects invalid kind [0.05ms]
|
|
181
|
-
(pass) PatternInversionResultSchema > validates a complete inversion result [0.
|
|
182
|
-
(pass) shouldInvertPattern > returns true when failure rate exceeds 60% [0.
|
|
181
|
+
(pass) PatternInversionResultSchema > validates a complete inversion result [0.13ms]
|
|
182
|
+
(pass) shouldInvertPattern > returns true when failure rate exceeds 60% [0.01ms]
|
|
183
183
|
(pass) shouldInvertPattern > returns true when failure rate equals 60% [0.02ms]
|
|
184
184
|
(pass) shouldInvertPattern > returns false when failure rate is below 60%
|
|
185
185
|
(pass) shouldInvertPattern > returns false when failure rate is just below threshold
|
|
@@ -188,43 +188,43 @@ src/anti-patterns.test.ts:
|
|
|
188
188
|
(pass) shouldInvertPattern > returns true when at minObservations with high failure rate
|
|
189
189
|
(pass) shouldInvertPattern > returns false when already an anti-pattern
|
|
190
190
|
(pass) shouldInvertPattern > returns false with zero observations
|
|
191
|
-
(pass) shouldInvertPattern > respects custom config minObservations
|
|
192
|
-
(pass) shouldInvertPattern > respects custom config failureRatioThreshold
|
|
193
|
-
(pass) invertToAntiPattern > converts pattern to anti-pattern with correct kind [0.
|
|
194
|
-
(pass) invertToAntiPattern > prefixes content with AVOID: [0.
|
|
191
|
+
(pass) shouldInvertPattern > respects custom config minObservations [0.01ms]
|
|
192
|
+
(pass) shouldInvertPattern > respects custom config failureRatioThreshold
|
|
193
|
+
(pass) invertToAntiPattern > converts pattern to anti-pattern with correct kind [0.02ms]
|
|
194
|
+
(pass) invertToAntiPattern > prefixes content with AVOID: [0.05ms]
|
|
195
195
|
(pass) invertToAntiPattern > appends reason to content [0.01ms]
|
|
196
|
-
(pass) invertToAntiPattern > preserves success and failure counts
|
|
196
|
+
(pass) invertToAntiPattern > preserves success and failure counts
|
|
197
197
|
(pass) invertToAntiPattern > preserves example_beads [0.01ms]
|
|
198
198
|
(pass) invertToAntiPattern > preserves tags
|
|
199
199
|
(pass) invertToAntiPattern > generates new ID with 'anti-' prefix
|
|
200
|
-
(pass) invertToAntiPattern > stores reason in inverted pattern
|
|
201
|
-
(pass) invertToAntiPattern > updates updated_at timestamp [0.
|
|
202
|
-
(pass) invertToAntiPattern > returns original pattern in result
|
|
203
|
-
(pass) invertToAntiPattern > returns reason in result
|
|
204
|
-
(pass) invertToAntiPattern > cleans existing AVOID: prefix [0.
|
|
205
|
-
(pass) invertToAntiPattern > cleans existing DO NOT: prefix [0.
|
|
206
|
-
(pass) invertToAntiPattern > cleans existing NEVER: prefix [0.
|
|
207
|
-
(pass) invertToAntiPattern > respects custom antiPatternPrefix [0.
|
|
208
|
-
(pass) recordPatternObservation > increments success count on success [0.
|
|
209
|
-
(pass) recordPatternObservation > increments failure count on failure
|
|
200
|
+
(pass) invertToAntiPattern > stores reason in inverted pattern
|
|
201
|
+
(pass) invertToAntiPattern > updates updated_at timestamp [0.02ms]
|
|
202
|
+
(pass) invertToAntiPattern > returns original pattern in result [0.01ms]
|
|
203
|
+
(pass) invertToAntiPattern > returns reason in result
|
|
204
|
+
(pass) invertToAntiPattern > cleans existing AVOID: prefix [0.01ms]
|
|
205
|
+
(pass) invertToAntiPattern > cleans existing DO NOT: prefix [0.03ms]
|
|
206
|
+
(pass) invertToAntiPattern > cleans existing NEVER: prefix [0.02ms]
|
|
207
|
+
(pass) invertToAntiPattern > respects custom antiPatternPrefix [0.02ms]
|
|
208
|
+
(pass) recordPatternObservation > increments success count on success [0.02ms]
|
|
209
|
+
(pass) recordPatternObservation > increments failure count on failure
|
|
210
210
|
(pass) recordPatternObservation > adds bead to example_beads when provided
|
|
211
|
-
(pass) recordPatternObservation > does not modify example_beads when beadId not provided
|
|
212
|
-
(pass) recordPatternObservation > limits example_beads to MAX_EXAMPLE_BEADS (10) [0.
|
|
211
|
+
(pass) recordPatternObservation > does not modify example_beads when beadId not provided
|
|
212
|
+
(pass) recordPatternObservation > limits example_beads to MAX_EXAMPLE_BEADS (10) [0.02ms]
|
|
213
213
|
(pass) recordPatternObservation > keeps newest beads when trimming example_beads [0.02ms]
|
|
214
|
-
(pass) recordPatternObservation > updates updated_at timestamp [0.
|
|
214
|
+
(pass) recordPatternObservation > updates updated_at timestamp [0.02ms]
|
|
215
215
|
(pass) recordPatternObservation > does not invert when below threshold [0.01ms]
|
|
216
216
|
(pass) recordPatternObservation > inverts when crossing threshold
|
|
217
217
|
(pass) recordPatternObservation > includes failure statistics in inversion reason [0.02ms]
|
|
218
|
-
(pass) recordPatternObservation > does not invert already-inverted anti-patterns [0.
|
|
218
|
+
(pass) recordPatternObservation > does not invert already-inverted anti-patterns [0.01ms]
|
|
219
219
|
(pass) recordPatternObservation > respects custom config for inversion [0.01ms]
|
|
220
|
-
(pass) recordPatternObservation > preserves original pattern fields [0.
|
|
221
|
-
(pass) extractPatternsFromDescription > detects 'split by file type' pattern [0.
|
|
222
|
-
(pass) extractPatternsFromDescription > detects 'splitting by file type' variant [0.
|
|
220
|
+
(pass) recordPatternObservation > preserves original pattern fields [0.02ms]
|
|
221
|
+
(pass) extractPatternsFromDescription > detects 'split by file type' pattern [0.06ms]
|
|
222
|
+
(pass) extractPatternsFromDescription > detects 'splitting by file type' variant [0.07ms]
|
|
223
223
|
(pass) extractPatternsFromDescription > detects 'split by component' pattern
|
|
224
224
|
(pass) extractPatternsFromDescription > detects 'split by layer' pattern
|
|
225
225
|
(pass) extractPatternsFromDescription > detects 'split by feature' pattern
|
|
226
226
|
(pass) extractPatternsFromDescription > detects 'one file per task' pattern
|
|
227
|
-
(pass) extractPatternsFromDescription > detects 'shared types first' pattern
|
|
227
|
+
(pass) extractPatternsFromDescription > detects 'shared types first' pattern
|
|
228
228
|
(pass) extractPatternsFromDescription > detects 'API routes separate' pattern
|
|
229
229
|
(pass) extractPatternsFromDescription > detects 'tests with code' pattern
|
|
230
230
|
(pass) extractPatternsFromDescription > detects 'tests in separate subtask' pattern
|
|
@@ -232,11 +232,11 @@ src/anti-patterns.test.ts:
|
|
|
232
232
|
(pass) extractPatternsFromDescription > detects 'sequential order' pattern
|
|
233
233
|
(pass) extractPatternsFromDescription > detects 'dependency chain' pattern
|
|
234
234
|
(pass) extractPatternsFromDescription > returns empty array for unrecognized descriptions
|
|
235
|
-
(pass) extractPatternsFromDescription > detects multiple patterns in one description
|
|
235
|
+
(pass) extractPatternsFromDescription > detects multiple patterns in one description [0.01ms]
|
|
236
236
|
(pass) extractPatternsFromDescription > is case-insensitive
|
|
237
237
|
(pass) extractPatternsFromDescription > handles partial matches in longer sentences
|
|
238
|
-
(pass) createPattern > creates pattern with provided content
|
|
239
|
-
(pass) createPattern > creates pattern with kind='pattern'
|
|
238
|
+
(pass) createPattern > creates pattern with provided content [0.02ms]
|
|
239
|
+
(pass) createPattern > creates pattern with kind='pattern'
|
|
240
240
|
(pass) createPattern > creates pattern with is_negative=false
|
|
241
241
|
(pass) createPattern > initializes counts to zero
|
|
242
242
|
(pass) createPattern > includes provided tags
|
|
@@ -251,231 +251,231 @@ src/anti-patterns.test.ts:
|
|
|
251
251
|
(pass) formatAntiPatternsForPrompt > returns empty string for empty array [0.01ms]
|
|
252
252
|
(pass) formatAntiPatternsForPrompt > formats multiple anti-patterns [0.01ms]
|
|
253
253
|
(pass) formatSuccessfulPatternsForPrompt > filters patterns below minSuccessRate [0.05ms]
|
|
254
|
-
(pass) formatSuccessfulPatternsForPrompt > includes success rate percentage in output
|
|
254
|
+
(pass) formatSuccessfulPatternsForPrompt > includes success rate percentage in output
|
|
255
255
|
(pass) formatSuccessfulPatternsForPrompt > filters out anti-patterns [0.01ms]
|
|
256
|
-
(pass) formatSuccessfulPatternsForPrompt > filters out patterns with < 2 total observations
|
|
257
|
-
(pass) formatSuccessfulPatternsForPrompt > returns empty string when no qualifying patterns
|
|
256
|
+
(pass) formatSuccessfulPatternsForPrompt > filters out patterns with < 2 total observations [0.01ms]
|
|
257
|
+
(pass) formatSuccessfulPatternsForPrompt > returns empty string when no qualifying patterns
|
|
258
258
|
(pass) formatSuccessfulPatternsForPrompt > returns empty string for empty array
|
|
259
|
-
(pass) formatSuccessfulPatternsForPrompt > uses default minSuccessRate of 0.7
|
|
259
|
+
(pass) formatSuccessfulPatternsForPrompt > uses default minSuccessRate of 0.7 [0.01ms]
|
|
260
260
|
(pass) formatSuccessfulPatternsForPrompt > respects custom minSuccessRate [0.01ms]
|
|
261
261
|
(pass) formatSuccessfulPatternsForPrompt > formats multiple successful patterns [0.01ms]
|
|
262
|
-
(pass) formatSuccessfulPatternsForPrompt > includes header when patterns exist [0.
|
|
263
|
-
(pass) InMemoryPatternStorage > stores and retrieves a pattern [0.
|
|
262
|
+
(pass) formatSuccessfulPatternsForPrompt > includes header when patterns exist [0.02ms]
|
|
263
|
+
(pass) InMemoryPatternStorage > stores and retrieves a pattern [0.06ms]
|
|
264
264
|
(pass) InMemoryPatternStorage > returns null for non-existent pattern [0.03ms]
|
|
265
|
-
(pass) InMemoryPatternStorage > updates existing pattern on store [0.
|
|
265
|
+
(pass) InMemoryPatternStorage > updates existing pattern on store [0.03ms]
|
|
266
266
|
(pass) InMemoryPatternStorage > getAll returns all stored patterns [0.06ms]
|
|
267
|
-
(pass) InMemoryPatternStorage > getAll returns empty array when no patterns [0.
|
|
268
|
-
(pass) InMemoryPatternStorage > getAntiPatterns filters by kind [0.
|
|
269
|
-
(pass) InMemoryPatternStorage > getByTag filters by tag [0.
|
|
270
|
-
(pass) InMemoryPatternStorage > getByTag returns empty for non-existent tag [0.
|
|
271
|
-
(pass) InMemoryPatternStorage > findByContent finds patterns by substring [0.
|
|
272
|
-
(pass) InMemoryPatternStorage > findByContent is case-insensitive [0.
|
|
273
|
-
(pass) InMemoryPatternStorage > findByContent returns empty for no matches [0.
|
|
267
|
+
(pass) InMemoryPatternStorage > getAll returns empty array when no patterns [0.03ms]
|
|
268
|
+
(pass) InMemoryPatternStorage > getAntiPatterns filters by kind [0.03ms]
|
|
269
|
+
(pass) InMemoryPatternStorage > getByTag filters by tag [0.10ms]
|
|
270
|
+
(pass) InMemoryPatternStorage > getByTag returns empty for non-existent tag [0.03ms]
|
|
271
|
+
(pass) InMemoryPatternStorage > findByContent finds patterns by substring [0.04ms]
|
|
272
|
+
(pass) InMemoryPatternStorage > findByContent is case-insensitive [0.03ms]
|
|
273
|
+
(pass) InMemoryPatternStorage > findByContent returns empty for no matches [0.01ms]
|
|
274
274
|
|
|
275
275
|
src/output-guardrails.test.ts:
|
|
276
|
-
(pass) truncateWithBoundaries > returns unchanged text when under limit [0.
|
|
277
|
-
(pass) truncateWithBoundaries > preserves complete JSON objects [6.
|
|
278
|
-
(pass) truncateWithBoundaries > preserves nested JSON structure [0.
|
|
279
|
-
(pass) truncateWithBoundaries > preserves code block boundaries [0.
|
|
280
|
-
(pass) truncateWithBoundaries > preserves markdown header boundaries [0.
|
|
276
|
+
(pass) truncateWithBoundaries > returns unchanged text when under limit [0.11ms]
|
|
277
|
+
(pass) truncateWithBoundaries > preserves complete JSON objects [6.37ms]
|
|
278
|
+
(pass) truncateWithBoundaries > preserves nested JSON structure [0.06ms]
|
|
279
|
+
(pass) truncateWithBoundaries > preserves code block boundaries [0.04ms]
|
|
280
|
+
(pass) truncateWithBoundaries > preserves markdown header boundaries [0.02ms]
|
|
281
281
|
(pass) truncateWithBoundaries > handles text without structure boundaries [0.02ms]
|
|
282
|
-
(pass) truncateWithBoundaries > adds truncation suffix with character count [0.
|
|
283
|
-
(pass) truncateWithBoundaries > avoids truncating mid-word [0.
|
|
284
|
-
(pass) truncateWithBoundaries > handles empty string
|
|
282
|
+
(pass) truncateWithBoundaries > adds truncation suffix with character count [0.04ms]
|
|
283
|
+
(pass) truncateWithBoundaries > avoids truncating mid-word [0.01ms]
|
|
284
|
+
(pass) truncateWithBoundaries > handles empty string [0.03ms]
|
|
285
285
|
(pass) truncateWithBoundaries > handles exact limit length
|
|
286
286
|
(pass) truncateWithBoundaries > handles just over limit [0.02ms]
|
|
287
287
|
(pass) truncateWithBoundaries > extends limit by 20% to include matching braces [0.01ms]
|
|
288
|
-
(pass) truncateWithBoundaries > extends limit by 20% to include closing code block [0.
|
|
289
|
-
(pass) guardrailOutput > skips configured tools [0.
|
|
290
|
-
(pass) guardrailOutput > truncates oversized output for non-skip tools [0.
|
|
291
|
-
(pass) guardrailOutput > respects per-tool limits [0.
|
|
292
|
-
(pass) guardrailOutput > uses custom config when provided [0.
|
|
288
|
+
(pass) truncateWithBoundaries > extends limit by 20% to include closing code block [0.01ms]
|
|
289
|
+
(pass) guardrailOutput > skips configured tools [0.02ms]
|
|
290
|
+
(pass) guardrailOutput > truncates oversized output for non-skip tools [0.57ms]
|
|
291
|
+
(pass) guardrailOutput > respects per-tool limits [0.17ms]
|
|
292
|
+
(pass) guardrailOutput > uses custom config when provided [0.03ms]
|
|
293
293
|
(pass) guardrailOutput > returns complete metadata [0.25ms]
|
|
294
|
-
(pass) guardrailOutput > handles all skip tools from DEFAULT_GUARDRAIL_CONFIG [0.
|
|
295
|
-
(pass) createMetrics > creates metrics entry from guardrail result [0.
|
|
296
|
-
(pass) createMetrics > timestamp is reasonable [0.
|
|
294
|
+
(pass) guardrailOutput > handles all skip tools from DEFAULT_GUARDRAIL_CONFIG [0.03ms]
|
|
295
|
+
(pass) createMetrics > creates metrics entry from guardrail result [0.04ms]
|
|
296
|
+
(pass) createMetrics > timestamp is reasonable [0.01ms]
|
|
297
297
|
(pass) DEFAULT_GUARDRAIL_CONFIG > has sensible defaults
|
|
298
|
-
(pass) DEFAULT_GUARDRAIL_CONFIG > includes higher limits for code/doc tools
|
|
298
|
+
(pass) DEFAULT_GUARDRAIL_CONFIG > includes higher limits for code/doc tools [0.01ms]
|
|
299
299
|
(pass) DEFAULT_GUARDRAIL_CONFIG > includes lower limits for stats tools
|
|
300
|
-
(pass) DEFAULT_GUARDRAIL_CONFIG > skips all internal coordination tools
|
|
301
|
-
(pass) edge cases > handles JSON array at truncation boundary [0.
|
|
300
|
+
(pass) DEFAULT_GUARDRAIL_CONFIG > skips all internal coordination tools
|
|
301
|
+
(pass) edge cases > handles JSON array at truncation boundary [0.03ms]
|
|
302
302
|
(pass) edge cases > handles mixed code blocks and JSON [0.02ms]
|
|
303
303
|
(pass) edge cases > handles unicode characters correctly [0.02ms]
|
|
304
|
-
(pass) edge cases > handles CRLF line endings
|
|
304
|
+
(pass) edge cases > handles CRLF line endings [0.01ms]
|
|
305
305
|
|
|
306
306
|
src/pattern-maturity.test.ts:
|
|
307
|
-
(pass) calculateDecayedCounts > returns zero counts for empty feedback
|
|
308
|
-
(pass) calculateDecayedCounts > counts recent helpful feedback at full weight [0.
|
|
309
|
-
(pass) calculateDecayedCounts > counts recent harmful feedback at full weight
|
|
310
|
-
(pass) calculateDecayedCounts > applies decay to old feedback [0.
|
|
311
|
-
(pass) calculateDecayedCounts > handles mixed feedback types
|
|
312
|
-
(pass) calculateDecayedCounts > respects weight parameter
|
|
313
|
-
(pass) calculateDecayedCounts > uses custom config half-life
|
|
314
|
-
(pass) calculateDecayedCounts > uses custom now parameter for decay calculation
|
|
315
|
-
(pass) calculateMaturityState > returns candidate with no feedback
|
|
316
|
-
(pass) calculateMaturityState > returns candidate with insufficient feedback [0.
|
|
317
|
-
(pass) calculateMaturityState > returns established with enough neutral feedback
|
|
307
|
+
(pass) calculateDecayedCounts > returns zero counts for empty feedback
|
|
308
|
+
(pass) calculateDecayedCounts > counts recent helpful feedback at full weight [0.10ms]
|
|
309
|
+
(pass) calculateDecayedCounts > counts recent harmful feedback at full weight [0.02ms]
|
|
310
|
+
(pass) calculateDecayedCounts > applies decay to old feedback [0.04ms]
|
|
311
|
+
(pass) calculateDecayedCounts > handles mixed feedback types [0.01ms]
|
|
312
|
+
(pass) calculateDecayedCounts > respects weight parameter [0.02ms]
|
|
313
|
+
(pass) calculateDecayedCounts > uses custom config half-life [0.03ms]
|
|
314
|
+
(pass) calculateDecayedCounts > uses custom now parameter for decay calculation [0.02ms]
|
|
315
|
+
(pass) calculateMaturityState > returns candidate with no feedback [0.03ms]
|
|
316
|
+
(pass) calculateMaturityState > returns candidate with insufficient feedback [0.01ms]
|
|
317
|
+
(pass) calculateMaturityState > returns established with enough neutral feedback [0.02ms]
|
|
318
318
|
(pass) calculateMaturityState > returns proven with strong positive feedback
|
|
319
|
-
(pass) calculateMaturityState > returns deprecated with high harmful ratio [0.
|
|
320
|
-
(pass) calculateMaturityState > proven requires minimum helpful count
|
|
321
|
-
(pass) calculateMaturityState > proven requires low harmful ratio [0.
|
|
322
|
-
(pass) calculateMaturityState > deprecation takes priority over proven
|
|
323
|
-
(pass) calculateMaturityState > uses custom config thresholds [0.
|
|
319
|
+
(pass) calculateMaturityState > returns deprecated with high harmful ratio [0.03ms]
|
|
320
|
+
(pass) calculateMaturityState > proven requires minimum helpful count [0.01ms]
|
|
321
|
+
(pass) calculateMaturityState > proven requires low harmful ratio [0.02ms]
|
|
322
|
+
(pass) calculateMaturityState > deprecation takes priority over proven [0.05ms]
|
|
323
|
+
(pass) calculateMaturityState > uses custom config thresholds [0.02ms]
|
|
324
324
|
(pass) calculateMaturityState > accounts for decay in state calculation [0.01ms]
|
|
325
|
-
(pass) createPatternMaturity > creates initial maturity in candidate state
|
|
325
|
+
(pass) createPatternMaturity > creates initial maturity in candidate state [0.01ms]
|
|
326
326
|
(pass) createPatternMaturity > sets last_validated timestamp [0.02ms]
|
|
327
327
|
(pass) createPatternMaturity > does not set promoted_at or deprecated_at initially [0.01ms]
|
|
328
|
-
(pass) updatePatternMaturity > updates state based on feedback [0.
|
|
329
|
-
(pass) updatePatternMaturity > updates helpful and harmful counts [0.
|
|
328
|
+
(pass) updatePatternMaturity > updates state based on feedback [0.04ms]
|
|
329
|
+
(pass) updatePatternMaturity > updates helpful and harmful counts [0.02ms]
|
|
330
330
|
(pass) updatePatternMaturity > sets promoted_at on first transition to proven [0.02ms]
|
|
331
|
-
(pass) updatePatternMaturity > does not update promoted_at if already proven [0.
|
|
332
|
-
(pass) updatePatternMaturity > sets deprecated_at on first transition to deprecated
|
|
333
|
-
(pass) updatePatternMaturity > does not update deprecated_at if already deprecated
|
|
334
|
-
(pass) updatePatternMaturity > updates last_validated timestamp
|
|
335
|
-
(pass) updatePatternMaturity > handles state transitions: candidate -> established [0.
|
|
331
|
+
(pass) updatePatternMaturity > does not update promoted_at if already proven [0.03ms]
|
|
332
|
+
(pass) updatePatternMaturity > sets deprecated_at on first transition to deprecated [0.04ms]
|
|
333
|
+
(pass) updatePatternMaturity > does not update deprecated_at if already deprecated [0.02ms]
|
|
334
|
+
(pass) updatePatternMaturity > updates last_validated timestamp [0.02ms]
|
|
335
|
+
(pass) updatePatternMaturity > handles state transitions: candidate -> established [0.02ms]
|
|
336
336
|
(pass) updatePatternMaturity > handles state transitions: established -> proven [0.04ms]
|
|
337
|
-
(pass) updatePatternMaturity > handles state transitions: proven -> deprecated [0.
|
|
338
|
-
(pass) updatePatternMaturity > handles empty feedback array
|
|
337
|
+
(pass) updatePatternMaturity > handles state transitions: proven -> deprecated [0.02ms]
|
|
338
|
+
(pass) updatePatternMaturity > handles empty feedback array [0.05ms]
|
|
339
339
|
[PatternMaturity] Promoting candidate with insufficient data: test-pattern (0 helpful observations)
|
|
340
|
-
(pass) promotePattern > promotes candidate to proven [0.
|
|
340
|
+
(pass) promotePattern > promotes candidate to proven [0.03ms]
|
|
341
341
|
(pass) promotePattern > promotes established to proven [0.01ms]
|
|
342
342
|
[PatternMaturity] Promoting candidate with insufficient data: test-pattern (0 helpful observations)
|
|
343
|
-
(pass) promotePattern > sets promoted_at timestamp [0.
|
|
343
|
+
(pass) promotePattern > sets promoted_at timestamp [0.02ms]
|
|
344
344
|
[PatternMaturity] Promoting candidate with insufficient data: test-pattern (0 helpful observations)
|
|
345
345
|
(pass) promotePattern > updates last_validated timestamp [0.02ms]
|
|
346
|
-
(pass) promotePattern > throws error when promoting deprecated pattern [0.
|
|
346
|
+
(pass) promotePattern > throws error when promoting deprecated pattern [0.01ms]
|
|
347
347
|
[PatternMaturity] Pattern already proven: test-pattern
|
|
348
|
-
(pass) promotePattern > returns unchanged maturity when already proven [0.
|
|
349
|
-
(pass) deprecatePattern > deprecates candidate pattern [0.
|
|
350
|
-
(pass) deprecatePattern > deprecates established pattern [0.
|
|
348
|
+
(pass) promotePattern > returns unchanged maturity when already proven [0.03ms]
|
|
349
|
+
(pass) deprecatePattern > deprecates candidate pattern [0.01ms]
|
|
350
|
+
(pass) deprecatePattern > deprecates established pattern [0.01ms]
|
|
351
351
|
(pass) deprecatePattern > deprecates proven pattern
|
|
352
|
-
(pass) deprecatePattern > sets deprecated_at timestamp [0.
|
|
352
|
+
(pass) deprecatePattern > sets deprecated_at timestamp [0.01ms]
|
|
353
353
|
(pass) deprecatePattern > updates last_validated timestamp [0.01ms]
|
|
354
|
-
(pass) deprecatePattern > returns unchanged maturity when already deprecated
|
|
354
|
+
(pass) deprecatePattern > returns unchanged maturity when already deprecated [0.01ms]
|
|
355
355
|
(pass) deprecatePattern > accepts optional reason parameter
|
|
356
356
|
(pass) getMaturityMultiplier > returns 0.5 for candidate [0.01ms]
|
|
357
357
|
(pass) getMaturityMultiplier > returns 1.0 for established
|
|
358
358
|
(pass) getMaturityMultiplier > returns 1.5 for proven
|
|
359
359
|
(pass) getMaturityMultiplier > returns 0 for deprecated
|
|
360
|
-
(pass) formatMaturityForPrompt > shows limited data for insufficient observations [0.
|
|
360
|
+
(pass) formatMaturityForPrompt > shows limited data for insufficient observations [0.03ms]
|
|
361
361
|
(pass) formatMaturityForPrompt > shows singular observation for count of 1 [0.01ms]
|
|
362
362
|
(pass) formatMaturityForPrompt > shows candidate with observation count when >= 3
|
|
363
363
|
(pass) formatMaturityForPrompt > shows established with percentages
|
|
364
|
-
(pass) formatMaturityForPrompt > shows proven with helpful percentage
|
|
364
|
+
(pass) formatMaturityForPrompt > shows proven with helpful percentage
|
|
365
365
|
(pass) formatMaturityForPrompt > shows deprecated with harmful percentage
|
|
366
366
|
(pass) formatMaturityForPrompt > rounds percentages correctly
|
|
367
|
-
(pass) formatMaturityForPrompt > handles zero counts edge case
|
|
368
|
-
(pass) formatPatternsWithMaturityForPrompt > formats empty map
|
|
369
|
-
(pass) formatPatternsWithMaturityForPrompt > groups patterns by maturity state [0.
|
|
367
|
+
(pass) formatMaturityForPrompt > handles zero counts edge case
|
|
368
|
+
(pass) formatPatternsWithMaturityForPrompt > formats empty map
|
|
369
|
+
(pass) formatPatternsWithMaturityForPrompt > groups patterns by maturity state [0.07ms]
|
|
370
370
|
(pass) formatPatternsWithMaturityForPrompt > omits sections with no patterns [0.02ms]
|
|
371
371
|
(pass) formatPatternsWithMaturityForPrompt > includes pattern maturity labels [0.02ms]
|
|
372
|
-
(pass) formatPatternsWithMaturityForPrompt > maintains multiple patterns in same section [0.
|
|
372
|
+
(pass) formatPatternsWithMaturityForPrompt > maintains multiple patterns in same section [0.03ms]
|
|
373
373
|
(pass) formatPatternsWithMaturityForPrompt > formats section headers correctly [0.01ms]
|
|
374
374
|
(pass) InMemoryMaturityStorage > store and get > stores and retrieves maturity by pattern ID [0.08ms]
|
|
375
|
-
(pass) InMemoryMaturityStorage > store and get > returns null for non-existent pattern
|
|
376
|
-
(pass) InMemoryMaturityStorage > store and get > overwrites existing maturity on store [0.
|
|
377
|
-
(pass) InMemoryMaturityStorage > getAll > returns empty array when no maturities stored [0.
|
|
378
|
-
(pass) InMemoryMaturityStorage > getAll > returns all stored maturities [0.
|
|
379
|
-
(pass) InMemoryMaturityStorage > getByState > returns empty array when no patterns match state [0.
|
|
375
|
+
(pass) InMemoryMaturityStorage > store and get > returns null for non-existent pattern [0.02ms]
|
|
376
|
+
(pass) InMemoryMaturityStorage > store and get > overwrites existing maturity on store [0.04ms]
|
|
377
|
+
(pass) InMemoryMaturityStorage > getAll > returns empty array when no maturities stored [0.03ms]
|
|
378
|
+
(pass) InMemoryMaturityStorage > getAll > returns all stored maturities [0.04ms]
|
|
379
|
+
(pass) InMemoryMaturityStorage > getByState > returns empty array when no patterns match state [0.03ms]
|
|
380
380
|
(pass) InMemoryMaturityStorage > getByState > returns only patterns matching state [0.05ms]
|
|
381
|
-
(pass) InMemoryMaturityStorage > getByState > handles multiple patterns with same state [0.
|
|
382
|
-
(pass) InMemoryMaturityStorage > storeFeedback and getFeedback > stores and retrieves feedback for pattern [0.
|
|
383
|
-
(pass) InMemoryMaturityStorage > storeFeedback and getFeedback > returns empty array for pattern with no feedback
|
|
384
|
-
(pass) InMemoryMaturityStorage > storeFeedback and getFeedback > stores multiple feedback events for same pattern [0.
|
|
385
|
-
(pass) InMemoryMaturityStorage > storeFeedback and getFeedback > filters feedback by pattern ID [0.
|
|
386
|
-
(pass) InMemoryMaturityStorage > storeFeedback and getFeedback > preserves feedback event data [0.
|
|
387
|
-
(pass) InMemoryMaturityStorage > integration: full workflow > supports complete maturity tracking workflow [0.
|
|
381
|
+
(pass) InMemoryMaturityStorage > getByState > handles multiple patterns with same state [0.03ms]
|
|
382
|
+
(pass) InMemoryMaturityStorage > storeFeedback and getFeedback > stores and retrieves feedback for pattern [0.04ms]
|
|
383
|
+
(pass) InMemoryMaturityStorage > storeFeedback and getFeedback > returns empty array for pattern with no feedback [0.03ms]
|
|
384
|
+
(pass) InMemoryMaturityStorage > storeFeedback and getFeedback > stores multiple feedback events for same pattern [0.04ms]
|
|
385
|
+
(pass) InMemoryMaturityStorage > storeFeedback and getFeedback > filters feedback by pattern ID [0.05ms]
|
|
386
|
+
(pass) InMemoryMaturityStorage > storeFeedback and getFeedback > preserves feedback event data [0.01ms]
|
|
387
|
+
(pass) InMemoryMaturityStorage > integration: full workflow > supports complete maturity tracking workflow [0.05ms]
|
|
388
388
|
|
|
389
389
|
src/mandate-promotion.test.ts:
|
|
390
|
-
(pass) shouldPromote > candidate stays candidate with insufficient votes [0.
|
|
391
|
-
(pass) shouldPromote > candidate → established at threshold (net_votes >= 2)
|
|
392
|
-
(pass) shouldPromote > candidate → established above threshold
|
|
390
|
+
(pass) shouldPromote > candidate stays candidate with insufficient votes [0.07ms]
|
|
391
|
+
(pass) shouldPromote > candidate → established at threshold (net_votes >= 2)
|
|
392
|
+
(pass) shouldPromote > candidate → established above threshold [0.01ms]
|
|
393
393
|
(pass) shouldPromote > established stays established with insufficient mandate votes
|
|
394
394
|
(pass) shouldPromote > established stays established with low vote ratio
|
|
395
395
|
(pass) shouldPromote > established → mandate at threshold (net >= 5, ratio >= 0.7)
|
|
396
396
|
(pass) shouldPromote > established → mandate above threshold
|
|
397
397
|
(pass) shouldPromote > mandate stays mandate (no demotion)
|
|
398
|
-
(pass) shouldPromote > candidate → rejected with negative votes
|
|
398
|
+
(pass) shouldPromote > candidate → rejected with negative votes
|
|
399
399
|
(pass) shouldPromote > established → rejected with negative votes
|
|
400
400
|
(pass) shouldPromote > rejected stays rejected (permanent)
|
|
401
|
-
(pass) shouldPromote > uses custom config thresholds [0.
|
|
402
|
-
(pass) evaluatePromotion > returns correct promotion result for candidate → established [0.
|
|
403
|
-
(pass) evaluatePromotion > returns correct promotion result for established → mandate [0.
|
|
401
|
+
(pass) shouldPromote > uses custom config thresholds [0.02ms]
|
|
402
|
+
(pass) evaluatePromotion > returns correct promotion result for candidate → established [0.06ms]
|
|
403
|
+
(pass) evaluatePromotion > returns correct promotion result for established → mandate [0.02ms]
|
|
404
404
|
(pass) evaluatePromotion > returns correct promotion result for candidate → rejected [0.02ms]
|
|
405
405
|
(pass) evaluatePromotion > returns correct result for no status change [0.02ms]
|
|
406
|
-
(pass) evaluatePromotion > returns correct result for mandate staying mandate [0.
|
|
406
|
+
(pass) evaluatePromotion > returns correct result for mandate staying mandate [0.01ms]
|
|
407
407
|
(pass) evaluatePromotion > returns correct result for rejected staying rejected [0.01ms]
|
|
408
|
-
(pass) decay affects promotion timing > net_votes can decay below promotion threshold
|
|
408
|
+
(pass) decay affects promotion timing > net_votes can decay below promotion threshold [0.01ms]
|
|
409
409
|
(pass) decay affects promotion timing > vote_ratio decay prevents mandate promotion [0.01ms]
|
|
410
|
-
(pass) decay affects promotion timing > fresh votes can push over mandate threshold
|
|
410
|
+
(pass) decay affects promotion timing > fresh votes can push over mandate threshold [0.01ms]
|
|
411
411
|
(pass) formatPromotionResult > formats promoted result with arrow [0.01ms]
|
|
412
|
-
(pass) formatPromotionResult > formats no-change result without arrow
|
|
413
|
-
(pass) evaluateBatchPromotions > evaluates multiple entries [0.
|
|
414
|
-
(pass) evaluateBatchPromotions > skips entries without scores
|
|
415
|
-
(pass) getStatusChanges > filters to only promoted entries [0.
|
|
416
|
-
(pass) groupByTransition > groups results by transition type [0.
|
|
417
|
-
(pass) groupByTransition > uses status name for no-change transitions
|
|
418
|
-
(pass) edge cases > handles exact threshold values
|
|
412
|
+
(pass) formatPromotionResult > formats no-change result without arrow [0.02ms]
|
|
413
|
+
(pass) evaluateBatchPromotions > evaluates multiple entries [0.05ms]
|
|
414
|
+
(pass) evaluateBatchPromotions > skips entries without scores [0.02ms]
|
|
415
|
+
(pass) getStatusChanges > filters to only promoted entries [0.01ms]
|
|
416
|
+
(pass) groupByTransition > groups results by transition type [0.05ms]
|
|
417
|
+
(pass) groupByTransition > uses status name for no-change transitions
|
|
418
|
+
(pass) edge cases > handles exact threshold values
|
|
419
419
|
(pass) edge cases > handles zero votes [0.02ms]
|
|
420
|
-
(pass) edge cases > handles negative vote ratio edge case
|
|
421
|
-
(pass) edge cases > rejects at exact rejection threshold
|
|
420
|
+
(pass) edge cases > handles negative vote ratio edge case [0.02ms]
|
|
421
|
+
(pass) edge cases > rejects at exact rejection threshold
|
|
422
422
|
|
|
423
423
|
src/schemas/index.test.ts:
|
|
424
|
-
(pass) BeadSchema > validates a complete bead [0.
|
|
425
|
-
(pass) BeadSchema > rejects invalid priority [0.
|
|
426
|
-
(pass) BeadSchema > accepts all valid types [0.
|
|
427
|
-
(pass) BeadCreateArgsSchema > validates minimal create args [0.
|
|
428
|
-
(pass) BeadCreateArgsSchema > rejects empty title [0.
|
|
429
|
-
(pass) EpicCreateArgsSchema > validates epic with subtasks [0.
|
|
430
|
-
(pass) EpicCreateArgsSchema > requires at least one subtask [0.
|
|
431
|
-
(pass) EvaluationSchema > validates a passing evaluation [0.
|
|
432
|
-
(pass) EvaluationSchema > validates a failing evaluation with retry suggestion [0.
|
|
433
|
-
(pass) TaskDecompositionSchema > validates a decomposition [0.
|
|
434
|
-
(pass) TaskDecompositionSchema > validates subtask effort levels [0.
|
|
435
|
-
(pass) SwarmStatusSchema > validates swarm status [0.
|
|
436
|
-
(pass) ValidationResultSchema > validates success result [0.
|
|
424
|
+
(pass) BeadSchema > validates a complete bead [0.50ms]
|
|
425
|
+
(pass) BeadSchema > rejects invalid priority [0.10ms]
|
|
426
|
+
(pass) BeadSchema > accepts all valid types [0.01ms]
|
|
427
|
+
(pass) BeadCreateArgsSchema > validates minimal create args [0.18ms]
|
|
428
|
+
(pass) BeadCreateArgsSchema > rejects empty title [0.07ms]
|
|
429
|
+
(pass) EpicCreateArgsSchema > validates epic with subtasks [0.22ms]
|
|
430
|
+
(pass) EpicCreateArgsSchema > requires at least one subtask [0.05ms]
|
|
431
|
+
(pass) EvaluationSchema > validates a passing evaluation [0.02ms]
|
|
432
|
+
(pass) EvaluationSchema > validates a failing evaluation with retry suggestion [0.04ms]
|
|
433
|
+
(pass) TaskDecompositionSchema > validates a decomposition [0.04ms]
|
|
434
|
+
(pass) TaskDecompositionSchema > validates subtask effort levels [0.04ms]
|
|
435
|
+
(pass) SwarmStatusSchema > validates swarm status [0.34ms]
|
|
436
|
+
(pass) ValidationResultSchema > validates success result [0.13ms]
|
|
437
437
|
(pass) ValidationResultSchema > validates failure result with errors [0.02ms]
|
|
438
438
|
|
|
439
439
|
src/schemas/cell-events.test.ts:
|
|
440
|
-
(pass) CellEventSchema > createCellEvent > creates valid cell_created event [0.
|
|
441
|
-
(pass) CellEventSchema > createCellEvent > creates valid cell_closed event [0.
|
|
442
|
-
(pass) CellEventSchema > createCellEvent > creates valid cell_dependency_added event [0.
|
|
443
|
-
(pass) CellEventSchema > createCellEvent > creates valid cell_epic_child_added event [0.
|
|
444
|
-
(pass) CellEventSchema > createCellEvent > throws on invalid event data [0.
|
|
445
|
-
(pass) CellEventSchema > type guards > isCellEventType narrows type correctly [0.
|
|
446
|
-
(pass) CellEventSchema > type guards > isStateTransitionEvent identifies status changes [0.
|
|
447
|
-
(pass) CellEventSchema > type guards > isEpicEvent identifies epic operations [0.
|
|
448
|
-
(pass) CellEventSchema > type guards > isAgentEvent detects agent-triggered events [0.
|
|
449
|
-
(pass) CellEventSchema > getCellIdFromEvent > extracts cell_id from any event [0.
|
|
450
|
-
(pass) CellEventSchema > discriminated union validation > validates against full CellEventSchema
|
|
440
|
+
(pass) CellEventSchema > createCellEvent > creates valid cell_created event [0.67ms]
|
|
441
|
+
(pass) CellEventSchema > createCellEvent > creates valid cell_closed event [0.20ms]
|
|
442
|
+
(pass) CellEventSchema > createCellEvent > creates valid cell_dependency_added event [0.25ms]
|
|
443
|
+
(pass) CellEventSchema > createCellEvent > creates valid cell_epic_child_added event [0.15ms]
|
|
444
|
+
(pass) CellEventSchema > createCellEvent > throws on invalid event data [0.07ms]
|
|
445
|
+
(pass) CellEventSchema > type guards > isCellEventType narrows type correctly [0.02ms]
|
|
446
|
+
(pass) CellEventSchema > type guards > isStateTransitionEvent identifies status changes [0.01ms]
|
|
447
|
+
(pass) CellEventSchema > type guards > isEpicEvent identifies epic operations [0.05ms]
|
|
448
|
+
(pass) CellEventSchema > type guards > isAgentEvent detects agent-triggered events [0.19ms]
|
|
449
|
+
(pass) CellEventSchema > getCellIdFromEvent > extracts cell_id from any event [0.02ms]
|
|
450
|
+
(pass) CellEventSchema > discriminated union validation > validates against full CellEventSchema [0.04ms]
|
|
451
451
|
(pass) CellEventSchema > discriminated union validation > rejects invalid event type [0.03ms]
|
|
452
|
-
(pass) CellEventSchema > discriminated union validation > validates dependency types [0.
|
|
453
|
-
(pass) CellEventSchema > event metadata > supports metadata field [0.
|
|
454
|
-
(pass) CellEventSchema > epic closure eligible event > creates valid closure eligible event [0.
|
|
455
|
-
(pass) CellEventSchema > status changed event > tracks status transitions [0.
|
|
456
|
-
(pass) CellEventSchema > status changed event > includes optional reason for blocked/closed
|
|
457
|
-
(pass) CellEventSchema > comment events > creates comment with optional parent [0.
|
|
458
|
-
(pass) CellEventSchema > work tracking events > tracks work start with file reservations [0.
|
|
452
|
+
(pass) CellEventSchema > discriminated union validation > validates dependency types [0.03ms]
|
|
453
|
+
(pass) CellEventSchema > event metadata > supports metadata field [0.01ms]
|
|
454
|
+
(pass) CellEventSchema > epic closure eligible event > creates valid closure eligible event [0.17ms]
|
|
455
|
+
(pass) CellEventSchema > status changed event > tracks status transitions [0.16ms]
|
|
456
|
+
(pass) CellEventSchema > status changed event > includes optional reason for blocked/closed [0.01ms]
|
|
457
|
+
(pass) CellEventSchema > comment events > creates comment with optional parent [0.15ms]
|
|
458
|
+
(pass) CellEventSchema > work tracking events > tracks work start with file reservations [0.16ms]
|
|
459
459
|
|
|
460
460
|
src/schemas/worker-handoff.test.ts:
|
|
461
|
-
(pass) WorkerHandoffContractSchema > valid contract parses correctly [0.
|
|
462
|
-
(pass) WorkerHandoffContractSchema > missing task_id fails [0.
|
|
463
|
-
(pass) WorkerHandoffContractSchema > empty files_owned is valid (read-only tasks) [0.
|
|
464
|
-
(pass) WorkerHandoffContractSchema > empty success_criteria fails [0.
|
|
465
|
-
(pass) WorkerHandoffContractSchema > empty task_id fails
|
|
466
|
-
(pass) WorkerHandoffContractSchema > short project name with hash is valid
|
|
467
|
-
(pass) WorkerHandoffContractSchema > partial hash is valid (resolvePartialId will expand it)
|
|
468
|
-
(pass) WorkerHandoffContextSchema > valid context parses correctly [0.
|
|
461
|
+
(pass) WorkerHandoffContractSchema > valid contract parses correctly [0.28ms]
|
|
462
|
+
(pass) WorkerHandoffContractSchema > missing task_id fails [0.08ms]
|
|
463
|
+
(pass) WorkerHandoffContractSchema > empty files_owned is valid (read-only tasks) [0.01ms]
|
|
464
|
+
(pass) WorkerHandoffContractSchema > empty success_criteria fails [0.03ms]
|
|
465
|
+
(pass) WorkerHandoffContractSchema > empty task_id fails [0.03ms]
|
|
466
|
+
(pass) WorkerHandoffContractSchema > short project name with hash is valid [0.02ms]
|
|
467
|
+
(pass) WorkerHandoffContractSchema > partial hash is valid (resolvePartialId will expand it) [0.02ms]
|
|
468
|
+
(pass) WorkerHandoffContextSchema > valid context parses correctly [0.09ms]
|
|
469
469
|
(pass) WorkerHandoffContextSchema > missing required fields fails [0.05ms]
|
|
470
|
-
(pass) WorkerHandoffContextSchema > empty strings are valid [0.
|
|
471
|
-
(pass) WorkerHandoffEscalationSchema > valid escalation parses correctly [0.
|
|
472
|
-
(pass) WorkerHandoffEscalationSchema > missing required fields fails [0.
|
|
473
|
-
(pass) WorkerHandoffSchema > complete valid handoff parses correctly [0.
|
|
474
|
-
(pass) WorkerHandoffSchema > missing contract section fails [0.
|
|
475
|
-
(pass) WorkerHandoffSchema > nested validation catches contract errors [0.
|
|
476
|
-
(pass) WorkerHandoffSchema > type inference works correctly
|
|
470
|
+
(pass) WorkerHandoffContextSchema > empty strings are valid [0.02ms]
|
|
471
|
+
(pass) WorkerHandoffEscalationSchema > valid escalation parses correctly [0.06ms]
|
|
472
|
+
(pass) WorkerHandoffEscalationSchema > missing required fields fails [0.02ms]
|
|
473
|
+
(pass) WorkerHandoffSchema > complete valid handoff parses correctly [0.10ms]
|
|
474
|
+
(pass) WorkerHandoffSchema > missing contract section fails [0.05ms]
|
|
475
|
+
(pass) WorkerHandoffSchema > nested validation catches contract errors [0.02ms]
|
|
476
|
+
(pass) WorkerHandoffSchema > type inference works correctly
|
|
477
477
|
|
|
478
478
|
425 pass
|
|
479
479
|
0 fail
|
|
480
480
|
776 expect() calls
|
|
481
|
-
Ran 425 tests across 10 files. [
|
|
481
|
+
Ran 425 tests across 10 files. [228.00ms]
|