@forwardimpact/libharness 0.1.16 → 0.1.18
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/README.md +2 -2
- package/package.json +15 -8
- package/src/fixture/cache.js +1 -1
- package/src/fixture/pathway.js +3 -3
package/README.md
CHANGED
|
@@ -38,8 +38,8 @@ import {
|
|
|
38
38
|
createMockProcess,
|
|
39
39
|
withSilentConsole,
|
|
40
40
|
createMockQueries,
|
|
41
|
-
//
|
|
42
|
-
|
|
41
|
+
// Agent-aligned engineering standard fixtures (pathway data)
|
|
42
|
+
createTestStandard,
|
|
43
43
|
createTestLevel,
|
|
44
44
|
createTestSkill,
|
|
45
45
|
createTestDiscipline,
|
package/package.json
CHANGED
|
@@ -1,7 +1,20 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@forwardimpact/libharness",
|
|
3
|
-
"version": "0.1.
|
|
4
|
-
"description": "Shared test
|
|
3
|
+
"version": "0.1.18",
|
|
4
|
+
"description": "Shared mocks and test fixtures so every library and service tests the same way.",
|
|
5
|
+
"keywords": [
|
|
6
|
+
"test",
|
|
7
|
+
"mock",
|
|
8
|
+
"fixture",
|
|
9
|
+
"harness",
|
|
10
|
+
"agent"
|
|
11
|
+
],
|
|
12
|
+
"forwardimpact": {
|
|
13
|
+
"capability": "foundations",
|
|
14
|
+
"needs": [
|
|
15
|
+
"Mock a config, storage, logger, or gRPC handler in a test"
|
|
16
|
+
]
|
|
17
|
+
},
|
|
5
18
|
"type": "module",
|
|
6
19
|
"main": "./src/index.js",
|
|
7
20
|
"exports": {
|
|
@@ -16,12 +29,6 @@
|
|
|
16
29
|
"scripts": {
|
|
17
30
|
"test": "bun test test/*.test.js"
|
|
18
31
|
},
|
|
19
|
-
"keywords": [
|
|
20
|
-
"test",
|
|
21
|
-
"mock",
|
|
22
|
-
"fixture",
|
|
23
|
-
"harness"
|
|
24
|
-
],
|
|
25
32
|
"author": "Forward Impact Team",
|
|
26
33
|
"license": "MIT",
|
|
27
34
|
"peerDependencies": {
|
package/src/fixture/cache.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Cross-file fixture caching helpers. The test runner currently executes one
|
|
3
3
|
* test file per process, but fixtures loaded inside a file (e.g. starter
|
|
4
|
-
*
|
|
4
|
+
* standard YAML via `createDataLoader().loadAllData(dir)`) are re-parsed for
|
|
5
5
|
* every `test(...)` case unless hoisted. See spec 620.
|
|
6
6
|
*/
|
|
7
7
|
|
package/src/fixture/pathway.js
CHANGED
|
@@ -359,7 +359,7 @@ export function createTestDisciplines() {
|
|
|
359
359
|
}
|
|
360
360
|
|
|
361
361
|
/**
|
|
362
|
-
* Builds a complete mock
|
|
362
|
+
* Builds a complete mock standard (capabilities, skills, disciplines, tracks,
|
|
363
363
|
* drivers, behaviours, levels) with sensible defaults. Per-slice overrides
|
|
364
364
|
* replace the default for that slice entirely.
|
|
365
365
|
*
|
|
@@ -371,9 +371,9 @@ export function createTestDisciplines() {
|
|
|
371
371
|
* @param {object[]} [overrides.drivers]
|
|
372
372
|
* @param {object[]} [overrides.behaviours]
|
|
373
373
|
* @param {object[]} [overrides.levels]
|
|
374
|
-
* @returns {object}
|
|
374
|
+
* @returns {object} Agent-aligned engineering standard with all slices populated.
|
|
375
375
|
*/
|
|
376
|
-
export function
|
|
376
|
+
export function createTestStandard(overrides = {}) {
|
|
377
377
|
return {
|
|
378
378
|
capabilities: overrides.capabilities ?? createTestCapabilities(),
|
|
379
379
|
skills: overrides.skills ?? createTestSkills(),
|