@ibgib/core-gib 0.0.8 → 0.0.11
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 +5 -10
- package/dist/assumptions.respec.d.mts +2 -0
- package/dist/assumptions.respec.d.mts.map +1 -0
- package/dist/assumptions.respec.mjs +41 -0
- package/dist/assumptions.respec.mjs.map +1 -0
- package/dist/core-constants.d.mts +0 -2
- package/dist/core-constants.d.mts.map +1 -1
- package/dist/core-constants.mjs +0 -2
- package/dist/core-constants.mjs.map +1 -1
- package/dist/core-helper.respec.d.mts +2 -0
- package/dist/core-helper.respec.d.mts.map +1 -0
- package/dist/core-helper.respec.mjs +53 -0
- package/dist/core-helper.respec.mjs.map +1 -0
- package/dist/core-types.d.mts +22 -0
- package/dist/core-types.d.mts.map +1 -1
- package/dist/respec-gib.node.d.mts +2 -0
- package/dist/respec-gib.node.d.mts.map +1 -0
- package/dist/respec-gib.node.mjs +211 -0
- package/dist/respec-gib.node.mjs.map +1 -0
- package/dist/spec-helper.node.respec.d.mts +12 -0
- package/dist/spec-helper.node.respec.d.mts.map +1 -0
- package/dist/spec-helper.node.respec.mjs +43 -0
- package/dist/spec-helper.node.respec.mjs.map +1 -0
- package/dist/witness/app/app-base-v1.d.mts +2 -2
- package/dist/witness/app/app-base-v1.d.mts.map +1 -1
- package/dist/witness/app/app-base-v1.mjs +23 -141
- package/dist/witness/app/app-base-v1.mjs.map +1 -1
- package/dist/witness/app/app-constants.d.mts +2 -0
- package/dist/witness/app/app-constants.d.mts.map +1 -1
- package/dist/witness/app/app-constants.mjs +2 -0
- package/dist/witness/app/app-constants.mjs.map +1 -1
- package/dist/witness/app/app-helper.d.mts.map +1 -1
- package/dist/witness/app/app-helper.mjs +2 -1
- package/dist/witness/app/app-helper.mjs.map +1 -1
- package/dist/witness/app/app-types.d.mts +2 -1
- package/dist/witness/app/app-types.d.mts.map +1 -1
- package/dist/witness/robbot/robbot-base-v1.d.mts +12 -164
- package/dist/witness/robbot/robbot-base-v1.d.mts.map +1 -1
- package/dist/witness/robbot/robbot-base-v1.mjs +41 -657
- package/dist/witness/robbot/robbot-base-v1.mjs.map +1 -1
- package/dist/witness/robbot/robbot-helper.mjs +3 -3
- package/dist/witness/robbot/robbot-helper.mjs.map +1 -1
- package/dist/witness/robbot/robbot-helper.respec.d.mts +2 -0
- package/dist/witness/robbot/robbot-helper.respec.d.mts.map +1 -0
- package/dist/witness/robbot/robbot-helper.respec.mjs +106 -0
- package/dist/witness/robbot/robbot-helper.respec.mjs.map +1 -0
- package/dist/witness/robbot/robbot-types.d.mts +6 -3
- package/dist/witness/robbot/robbot-types.d.mts.map +1 -1
- package/dist/witness/robbot/robbot-types.mjs +1 -0
- package/dist/witness/robbot/robbot-types.mjs.map +1 -1
- package/dist/witness/space/filesystem-space/filesystem-space-v1.d.mts +1 -1
- package/dist/witness/space/filesystem-space/filesystem-space-v1.d.mts.map +1 -1
- package/dist/witness/space/filesystem-space/filesystem-space-v1.respec.d.mts +2 -0
- package/dist/witness/space/filesystem-space/filesystem-space-v1.respec.d.mts.map +1 -0
- package/dist/witness/space/filesystem-space/filesystem-space-v1.respec.mjs +107 -0
- package/dist/witness/space/filesystem-space/filesystem-space-v1.respec.mjs.map +1 -0
- package/dist/witness/space/filesystem-space/node-filesystem-space-v1.d.mts.map +1 -1
- package/dist/witness/space/filesystem-space/node-filesystem-space-v1.mjs +1 -1
- package/dist/witness/space/filesystem-space/node-filesystem-space-v1.mjs.map +1 -1
- package/dist/witness/space/filesystem-space/node-filesystem-space-v1.node.respec.d.mts +2 -0
- package/dist/witness/space/filesystem-space/node-filesystem-space-v1.node.respec.d.mts.map +1 -0
- package/dist/witness/space/filesystem-space/node-filesystem-space-v1.node.respec.mjs +129 -0
- package/dist/witness/space/filesystem-space/node-filesystem-space-v1.node.respec.mjs.map +1 -0
- package/dist/witness/space/inner-space/inner-space-v1.respec.d.mts +2 -0
- package/dist/witness/space/inner-space/inner-space-v1.respec.d.mts.map +1 -0
- package/dist/witness/space/inner-space/inner-space-v1.respec.mjs +56 -0
- package/dist/witness/space/inner-space/inner-space-v1.respec.mjs.map +1 -0
- package/dist/witness/space/metaspace/metaspace-base.d.mts +795 -0
- package/dist/witness/space/metaspace/metaspace-base.d.mts.map +1 -0
- package/dist/witness/space/metaspace/metaspace-base.mjs +3251 -0
- package/dist/witness/space/metaspace/metaspace-base.mjs.map +1 -0
- package/dist/witness/space/metaspace/metaspace-innerspace/metaspace-innerspace-helper.d.mts +4 -0
- package/dist/witness/space/metaspace/metaspace-innerspace/metaspace-innerspace-helper.d.mts.map +1 -0
- package/dist/witness/space/metaspace/metaspace-innerspace/metaspace-innerspace-helper.mjs +117 -0
- package/dist/witness/space/metaspace/metaspace-innerspace/metaspace-innerspace-helper.mjs.map +1 -0
- package/dist/witness/space/metaspace/metaspace-innerspace/metaspace-innerspace.d.mts +34 -0
- package/dist/witness/space/metaspace/metaspace-innerspace/metaspace-innerspace.d.mts.map +1 -0
- package/dist/witness/space/metaspace/metaspace-innerspace/metaspace-innerspace.mjs +76 -0
- package/dist/witness/space/metaspace/metaspace-innerspace/metaspace-innerspace.mjs.map +1 -0
- package/dist/witness/space/metaspace/metaspace-types.d.mts +580 -0
- package/dist/witness/space/metaspace/metaspace-types.d.mts.map +1 -0
- package/dist/witness/space/metaspace/metaspace-types.mjs +6 -0
- package/dist/witness/space/metaspace/metaspace-types.mjs.map +1 -0
- package/dist/witness/space/space-helper.d.mts.map +1 -1
- package/dist/witness/space/space-helper.mjs +2 -1
- package/dist/witness/space/space-helper.mjs.map +1 -1
- package/dist/witness/space/{space-spec-helper.d.mts → space-respec-helper.d.mts} +15 -5
- package/dist/witness/space/space-respec-helper.d.mts.map +1 -0
- package/dist/witness/space/space-respec-helper.mjs +186 -0
- package/dist/witness/space/space-respec-helper.mjs.map +1 -0
- package/dist/witness/space/space-types.d.mts +2 -1
- package/dist/witness/space/space-types.d.mts.map +1 -1
- package/dist/witness/space/space-types.mjs.map +1 -1
- package/dist/witness/witness-base-v1.d.mts.map +1 -1
- package/dist/witness/witness-base-v1.mjs +7 -7
- package/dist/witness/witness-base-v1.mjs.map +1 -1
- package/dist/witness/witness-cmd/witness-cmd-types.d.mts +31 -0
- package/dist/witness/witness-cmd/witness-cmd-types.d.mts.map +1 -0
- package/dist/witness/witness-cmd/witness-cmd-types.mjs +2 -0
- package/dist/witness/witness-cmd/witness-cmd-types.mjs.map +1 -0
- package/dist/witness/witness-helper.d.mts +8 -0
- package/dist/witness/witness-helper.d.mts.map +1 -1
- package/dist/witness/witness-helper.mjs +30 -0
- package/dist/witness/witness-helper.mjs.map +1 -1
- package/dist/witness/witness-types.d.mts +26 -36
- package/dist/witness/witness-types.d.mts.map +1 -1
- package/dist/witness/witness-with-context/witness-with-context-base-v1.d.mts +235 -0
- package/dist/witness/witness-with-context/witness-with-context-base-v1.d.mts.map +1 -0
- package/dist/witness/witness-with-context/witness-with-context-base-v1.mjs +742 -0
- package/dist/witness/witness-with-context/witness-with-context-base-v1.mjs.map +1 -0
- package/dist/witness/witness-with-context/witness-with-context-types.d.mts +17 -0
- package/dist/witness/witness-with-context/witness-with-context-types.d.mts.map +1 -0
- package/dist/witness/witness-with-context/witness-with-context-types.mjs +2 -0
- package/dist/witness/witness-with-context/witness-with-context-types.mjs.map +1 -0
- package/package.json +12 -15
- package/src/{assumptions.spec.mts → assumptions.respec.mts} +11 -5
- package/src/core-constants.mts +0 -2
- package/src/core-helper.respec.mts +71 -0
- package/src/core-types.mts +20 -0
- package/src/respec-gib.node.mts +199 -0
- package/src/witness/app/app-base-v1.mts +19 -212
- package/src/witness/app/app-constants.mts +3 -0
- package/src/witness/app/app-helper.mts +2 -1
- package/src/witness/app/app-types.mts +1 -1
- package/src/witness/robbot/robbot-base-v1.mts +39 -690
- package/src/witness/robbot/robbot-helper.mts +1 -1
- package/src/witness/robbot/{robbot-helper.spec.mts → robbot-helper.respec.mts} +39 -33
- package/src/witness/robbot/robbot-types.mts +5 -3
- package/src/witness/space/filesystem-space/filesystem-space-v1.mts +1 -1
- package/src/witness/space/filesystem-space/{filesystem-space-v1.spec.mts → filesystem-space-v1.respec.mts} +17 -8
- package/src/witness/space/filesystem-space/node-filesystem-space-v1.mts +3 -11
- package/src/witness/space/filesystem-space/{node-filesystem-space-v1.node.spec.mts → node-filesystem-space-v1.node.respec.mts} +18 -14
- package/src/witness/space/inner-space/{inner-space-v1.spec.mts → inner-space-v1.respec.mts} +17 -8
- package/src/witness/space/metaspace/metaspace-base.mts +3702 -0
- package/src/witness/space/metaspace/metaspace-innerspace/metaspace-innerspace-helper.mts +116 -0
- package/src/witness/space/metaspace/metaspace-innerspace/metaspace-innerspace.mts +88 -0
- package/src/witness/space/metaspace/metaspace-types.mts +614 -0
- package/src/witness/space/space-helper.mts +2 -1
- package/src/witness/space/{space-spec-helper.mts → space-respec-helper.mts} +76 -57
- package/src/witness/space/space-types.mts +2 -1
- package/src/witness/witness-base-v1.mts +8 -6
- package/src/witness/witness-cmd/witness-cmd-types.mts +38 -0
- package/src/witness/witness-helper.mts +31 -0
- package/src/witness/witness-types.mts +31 -41
- package/src/witness/witness-with-context/witness-with-context-base-v1.mts +809 -0
- package/src/witness/witness-with-context/witness-with-context-types.mts +24 -0
- package/tsconfig.json +1 -0
- package/dist/witness/space/space-spec-helper.d.mts.map +0 -1
- package/dist/witness/space/space-spec-helper.mjs +0 -179
- package/dist/witness/space/space-spec-helper.mjs.map +0 -1
- package/jasmine-browser.json +0 -18
- package/jasmine.json +0 -6
- package/src/core-helper.spec.mts +0 -64
- /package/src/{spec-helper.node.spec.mts → spec-helper.node.respec.mts} +0 -0
|
@@ -97,11 +97,11 @@ export async function validateCommonRobbotIbGib({
|
|
|
97
97
|
}): Promise<string[] | undefined> {
|
|
98
98
|
const lc = `[${validateCommonRobbotIbGib.name}]`;
|
|
99
99
|
try {
|
|
100
|
+
if (logalot) { console.log(`${lc} starting... (I: f7b34d791a483b8c5a9d188da66d3f22)`); }
|
|
100
101
|
const intrinsicErrors: string[] = await validateIbGibIntrinsically({ ibGib: robbotIbGib }) ?? [];
|
|
101
102
|
|
|
102
103
|
if (!robbotIbGib.data) { throw new Error(`robbotIbGib.data required (E: 754a8d2540610696aff04b0d159daa23)`); }
|
|
103
104
|
const ibErrors: string[] = [];
|
|
104
|
-
if (logalot) { console.log(`${lc} starting... (I: f7b34d791a483b8c5a9d188da66d3f22)`); }
|
|
105
105
|
let { robbotClassname, robbotName, robbotId } = parseRobbotIb({ robbotIb: robbotIbGib.ib });
|
|
106
106
|
if (!robbotClassname) { ibErrors.push(`robbotClassname required (E: 3234d39bf1c74ec3aff59f374282dfc8)`); }
|
|
107
107
|
if (!robbotName) { ibErrors.push(`robbotName required (E: b329dcc62ff548d7aa0681393b2c7057)`); }
|
|
@@ -1,3 +1,9 @@
|
|
|
1
|
+
import {
|
|
2
|
+
firstOfEach, firstOfAll, ifWe,
|
|
3
|
+
lastOfEach, lastOfAll,
|
|
4
|
+
ifWeMight, iReckon, respecfully
|
|
5
|
+
} from '@ibgib/helper-gib/dist/respec-gib/respec-gib.mjs';
|
|
6
|
+
const maam = `[${import.meta.url}]`, sir = maam;
|
|
1
7
|
// import { getIbAndGib } from '@ibgib/ts-gib';
|
|
2
8
|
// import { IbGib_V1 } from '@ibgib/ts-gib/dist/V1/index.mjs';
|
|
3
9
|
// import { getGibInfo } from 'ts-gib/dist/V1/transforms/transform-helper';
|
|
@@ -10,9 +16,9 @@
|
|
|
10
16
|
import { IbGib_V1 } from "@ibgib/ts-gib/dist/V1/types.mjs";
|
|
11
17
|
import { getSpaceDelimitedSaferRequestText } from "./robbot-helper.mjs";
|
|
12
18
|
|
|
13
|
-
|
|
19
|
+
await respecfully(sir, 'getRequestTextFromComment', async () => {
|
|
14
20
|
|
|
15
|
-
|
|
21
|
+
await ifWe(sir, 'should get request text with single-char escape', () => {
|
|
16
22
|
['?', '??', '/', '/esc'].forEach(escape => {
|
|
17
23
|
['help', 'hi',].forEach(requestText => {
|
|
18
24
|
const text = escape + requestText;
|
|
@@ -23,7 +29,7 @@ describe('getRequestTextFromComment', () => {
|
|
|
23
29
|
data: { text }
|
|
24
30
|
}
|
|
25
31
|
const resRequestText = getSpaceDelimitedSaferRequestText({ ibGib, requestEscapeString: escape });
|
|
26
|
-
|
|
32
|
+
iReckon(sir, resRequestText).isGonnaBe(requestText);
|
|
27
33
|
});
|
|
28
34
|
});
|
|
29
35
|
});
|
|
@@ -31,7 +37,7 @@ describe('getRequestTextFromComment', () => {
|
|
|
31
37
|
|
|
32
38
|
|
|
33
39
|
|
|
34
|
-
//
|
|
40
|
+
// await respecfully(sir, 'RobbotSessionIb', () => {
|
|
35
41
|
|
|
36
42
|
// // one big test because jasmine unfortunately makes you declare variables
|
|
37
43
|
// // multiple times to get async working, which doesn't scale, so it's a bad
|
|
@@ -58,12 +64,12 @@ describe('getRequestTextFromComment', () => {
|
|
|
58
64
|
// contextTjpGib: commentGibInfo.tjpGib,
|
|
59
65
|
// sessionId,
|
|
60
66
|
// });
|
|
61
|
-
// expect(ib).
|
|
62
|
-
// expect(ib.startsWith(ROBBOT_SESSION_ATOM)).
|
|
63
|
-
// expect(ib.match(timestampInTicks)).
|
|
64
|
-
// expect(ib.match(sessionId)).
|
|
65
|
-
// expect(ib.match(robbot.data.name)).
|
|
66
|
-
// expect(ib.match(robbot.data.uuid)).
|
|
67
|
+
// expect(ib).isGonnaBeTruthy();
|
|
68
|
+
// expect(ib.startsWith(ROBBOT_SESSION_ATOM)).isGonnaBe(true, `doesnt start with robbot session atom. (${ib})`);
|
|
69
|
+
// expect(ib.match(timestampInTicks)).isGonnaBeTruthy(`timestampInTicks not included. (${ib}\n${timestampInTicks})`);
|
|
70
|
+
// expect(ib.match(sessionId)).isGonnaBeTruthy(`sessionId.\nib: ${ib}\nsessionId: ${sessionId}`);
|
|
71
|
+
// expect(ib.match(robbot.data.name)).isGonnaBeTruthy('robbot name');
|
|
72
|
+
// expect(ib.match(robbot.data.uuid)).isGonnaBeTruthy('robbot uuid');
|
|
67
73
|
|
|
68
74
|
// let { timestamp, robbotName,
|
|
69
75
|
// robbotClassname, robbotId, robbotTjpGib,
|
|
@@ -71,14 +77,14 @@ describe('getRequestTextFromComment', () => {
|
|
|
71
77
|
// addlMetadata: addlMetadata_Out
|
|
72
78
|
// } = parseRobbotSessionIb({ ib });
|
|
73
79
|
|
|
74
|
-
// expect(timestamp).
|
|
75
|
-
// expect(robbotName).
|
|
76
|
-
// expect(robbotClassname).
|
|
77
|
-
// expect(robbotId).
|
|
78
|
-
// expect(robbotTjpGib).
|
|
79
|
-
// expect(sessionId_Out).
|
|
80
|
-
// expect(contextTjpGib).
|
|
81
|
-
// expect(addlMetadata_Out).
|
|
80
|
+
// expect(timestamp).isGonnaBe(timestampInTicks, 'timestampInTicks');
|
|
81
|
+
// expect(robbotName).isGonnaBe(robbot.data.name, 'robbot name');
|
|
82
|
+
// expect(robbotClassname).isGonnaBe(robbot.data.classname, 'robbot classname');
|
|
83
|
+
// expect(robbotId).isGonnaBe(robbot.data.uuid, 'robbot uuid');
|
|
84
|
+
// expect(robbotTjpGib).isGonnaBe(getGibInfo({ gib: robbot.gib }).tjpGib, 'robbot tjpgib');
|
|
85
|
+
// expect(sessionId_Out).isGonnaBe(sessionId, 'sessionId');
|
|
86
|
+
// expect(contextTjpGib).isGonnaBe(getGibInfo({ gib: commentIbGib.gib }).tjpGib, 'contextTjpGib');
|
|
87
|
+
// expect(addlMetadata_Out).isGonnaBe(undefined, 'addlMetadata');
|
|
82
88
|
|
|
83
89
|
// // #endregion get/parse normal, no metadata
|
|
84
90
|
|
|
@@ -92,13 +98,13 @@ describe('getRequestTextFromComment', () => {
|
|
|
92
98
|
// addlMetadata,
|
|
93
99
|
// });
|
|
94
100
|
|
|
95
|
-
// expect(ib).
|
|
96
|
-
// expect(ib.startsWith(ROBBOT_SESSION_ATOM)).
|
|
97
|
-
// expect(ib.match(timestampInTicks)).
|
|
98
|
-
// expect(ib.match(sessionId)).
|
|
99
|
-
// expect(ib.match(robbot.data.name)).
|
|
100
|
-
// expect(ib.match(robbot.data.uuid)).
|
|
101
|
-
// expect(ib.match(addlMetadata)).
|
|
101
|
+
// expect(ib).isGonnaBeTruthy();
|
|
102
|
+
// expect(ib.startsWith(ROBBOT_SESSION_ATOM)).isGonnaBe(true, `2 doesnt start with robbot session atom. (${ib})`);
|
|
103
|
+
// expect(ib.match(timestampInTicks)).isGonnaBeTruthy(`2 timestampInTicks not included. (${ib}\n${timestampInTicks})`);
|
|
104
|
+
// expect(ib.match(sessionId)).isGonnaBeTruthy(`2 sessionId.\nib: ${ib}\nsessionId: ${sessionId}`);
|
|
105
|
+
// expect(ib.match(robbot.data.name)).isGonnaBeTruthy('2 robbot name');
|
|
106
|
+
// expect(ib.match(robbot.data.uuid)).isGonnaBeTruthy('2 robbot uuid');
|
|
107
|
+
// expect(ib.match(addlMetadata)).isGonnaBeTruthy('addlMetadata');
|
|
102
108
|
|
|
103
109
|
// // thanks https://flaviocopes.com/javascript-destructure-object-to-existing-variable/
|
|
104
110
|
// ({
|
|
@@ -107,14 +113,14 @@ describe('getRequestTextFromComment', () => {
|
|
|
107
113
|
// sessionId: sessionId_Out, contextTjpGib, addlMetadata: addlMetadata_Out
|
|
108
114
|
// } = parseRobbotSessionIb({ ib }));
|
|
109
115
|
|
|
110
|
-
// expect(timestamp).
|
|
111
|
-
// expect(robbotName).
|
|
112
|
-
// expect(robbotClassname).
|
|
113
|
-
// expect(robbotId).
|
|
114
|
-
// expect(robbotTjpGib).
|
|
115
|
-
// expect(sessionId_Out).
|
|
116
|
-
// expect(contextTjpGib).
|
|
117
|
-
// expect(addlMetadata_Out).
|
|
116
|
+
// expect(timestamp).isGonnaBe(timestampInTicks, '2 timestampInTicks');
|
|
117
|
+
// expect(robbotName).isGonnaBe(robbot.data.name, '2 robbot name');
|
|
118
|
+
// expect(robbotClassname).isGonnaBe(robbot.data.classname, '2 robbot classname');
|
|
119
|
+
// expect(robbotId).isGonnaBe(robbot.data.uuid, '2 robbot uuid');
|
|
120
|
+
// expect(robbotTjpGib).isGonnaBe(getGibInfo({ gib: robbot.gib }).tjpGib, '2 robbot tjpgib');
|
|
121
|
+
// expect(sessionId_Out).isGonnaBe(sessionId, '2 sessionId');
|
|
122
|
+
// expect(contextTjpGib).isGonnaBe(getGibInfo({ gib: commentIbGib.gib }).tjpGib, '2 contextTjpGib');
|
|
123
|
+
// expect(addlMetadata_Out).isGonnaBe(addlMetadata, 'addlMetadata');
|
|
118
124
|
|
|
119
125
|
// // #endregion with addl metadata
|
|
120
126
|
|
|
@@ -5,17 +5,18 @@ import { IbGibData_V1, IbGibRel8ns_V1, IbGib_V1 } from '@ibgib/ts-gib/dist/V1/in
|
|
|
5
5
|
|
|
6
6
|
import {
|
|
7
7
|
WitnessData_V1, WitnessRel8ns_V1,
|
|
8
|
-
WitnessCmdData, WitnessCmdRel8ns, WitnessCmdIbGib,
|
|
9
8
|
WitnessResultData, WitnessResultRel8ns, WitnessResultIbGib,
|
|
10
9
|
} from '../witness-types.mjs';
|
|
11
10
|
import { CommentIbGib_V1 } from '../../common/comment/comment-types.mjs';
|
|
12
11
|
import { ROBBOT_TAG_TJP_ADDRS_REL8N_NAME } from './robbot-constants.mjs';
|
|
13
12
|
import { IbGibRobbotAny } from './robbot-base-v1.mjs';
|
|
13
|
+
import { WitnessWithContextData_V1, WitnessWithContextRel8ns_V1 } from '../witness-with-context/witness-with-context-types.mjs';
|
|
14
|
+
import { WitnessCmdData, WitnessCmdRel8ns, WitnessCmdIbGib, } from '../witness-cmd/witness-cmd-types.mjs';
|
|
14
15
|
|
|
15
16
|
|
|
16
17
|
export type RobbotTransparency = 'transparent' | 'translucent' | 'opaque';
|
|
17
18
|
|
|
18
|
-
export interface RobbotData_V1 extends
|
|
19
|
+
export interface RobbotData_V1 extends WitnessWithContextData_V1 {
|
|
19
20
|
|
|
20
21
|
/**
|
|
21
22
|
* Name of a Robbot instance...after all, Robbie was only the first Robbot.
|
|
@@ -172,7 +173,7 @@ export const DEFAULT_ROBBOT_REQUEST_MAX_LENGTH = 100;
|
|
|
172
173
|
// }
|
|
173
174
|
// export const VALID_ROBBOT_OUTPUT_MODES = Object.values(RobbotOutputMode);
|
|
174
175
|
|
|
175
|
-
export interface RobbotRel8ns_V1 extends
|
|
176
|
+
export interface RobbotRel8ns_V1 extends WitnessWithContextRel8ns_V1 {
|
|
176
177
|
[ROBBOT_TAG_TJP_ADDRS_REL8N_NAME]?: TjpIbGibAddr[];
|
|
177
178
|
}
|
|
178
179
|
|
|
@@ -338,6 +339,7 @@ export const ROBBOT_SESSION_REL8N_NAME = 'session';
|
|
|
338
339
|
*/
|
|
339
340
|
export const ROBBOT_INTERACTION_REL8N_NAME = 'interaction';
|
|
340
341
|
|
|
342
|
+
export const ROBBOT_ATOM = "robbot";
|
|
341
343
|
export const ROBBOT_SESSION_ATOM = 'robbot_session';
|
|
342
344
|
export const ROBBOT_ANALYSIS_ATOM = 'robbot_analysis';
|
|
343
345
|
export const ROBBOT_INTERACTION_ATOM = 'robbot_interaction';
|
|
@@ -266,7 +266,7 @@ export abstract class FilesystemSpace_V1<
|
|
|
266
266
|
TResultData extends FilesystemSpaceResultData,
|
|
267
267
|
TResultRel8ns extends FilesystemSpaceResultRel8ns,
|
|
268
268
|
TData extends FilesystemSpaceData_V1 = FilesystemSpaceData_V1,
|
|
269
|
-
TRel8ns extends
|
|
269
|
+
TRel8ns extends FilesystemSpaceRel8ns_V1 = FilesystemSpaceRel8ns_V1
|
|
270
270
|
> extends SpaceBase_V1<
|
|
271
271
|
IbGib_V1,
|
|
272
272
|
TOptionsData,
|
|
@@ -1,3 +1,9 @@
|
|
|
1
|
+
import {
|
|
2
|
+
firstOfEach, firstOfAll, ifWe,
|
|
3
|
+
lastOfEach, lastOfAll,
|
|
4
|
+
ifWeMight, iReckon, respecfully
|
|
5
|
+
} from '@ibgib/helper-gib/dist/respec-gib/respec-gib.mjs';
|
|
6
|
+
const maam = `[${import.meta.url}]`, sir = maam;
|
|
1
7
|
import { getUUID, } from '@ibgib/helper-gib';
|
|
2
8
|
import { getIbGibAddr } from '@ibgib/ts-gib';
|
|
3
9
|
|
|
@@ -5,7 +11,7 @@ import {
|
|
|
5
11
|
testSpace_createAndInit,
|
|
6
12
|
testSpace_persistTransformResult,
|
|
7
13
|
testSpace_PutGetDelete
|
|
8
|
-
} from '../space-
|
|
14
|
+
} from '../space-respec-helper.mjs';
|
|
9
15
|
import { FilesystemSpace_V1, } from './filesystem-space-v1.mjs';
|
|
10
16
|
import {
|
|
11
17
|
PutIbGibFileOpts, PutIbGibFileResult,
|
|
@@ -48,10 +54,11 @@ class MockFilesystemSpace_V1 extends FilesystemSpace_V1<any, any, any, any> {
|
|
|
48
54
|
|
|
49
55
|
}
|
|
50
56
|
|
|
51
|
-
|
|
57
|
+
await respecfully(sir, `[${FilesystemSpace_V1.name} specs]`, async () => {
|
|
52
58
|
|
|
53
|
-
testSpace_createAndInit({
|
|
54
|
-
|
|
59
|
+
await testSpace_createAndInit({
|
|
60
|
+
respecfulTitle: sir,
|
|
61
|
+
// shortcircuitRespec: true,
|
|
55
62
|
fnGetInitialData: async () => {
|
|
56
63
|
return {
|
|
57
64
|
name: (await getUUID()).substring(0, 8),
|
|
@@ -66,8 +73,9 @@ describe(`[${FilesystemSpace_V1.name} specs]`, () => {
|
|
|
66
73
|
},
|
|
67
74
|
})
|
|
68
75
|
|
|
69
|
-
testSpace_PutGetDelete({
|
|
70
|
-
|
|
76
|
+
await testSpace_PutGetDelete({
|
|
77
|
+
respecfulTitle: sir,
|
|
78
|
+
// shortcircuitRespec: true,
|
|
71
79
|
fnGetInitialData: async () => {
|
|
72
80
|
return {
|
|
73
81
|
name: (await getUUID()).substring(0, 8),
|
|
@@ -82,8 +90,9 @@ describe(`[${FilesystemSpace_V1.name} specs]`, () => {
|
|
|
82
90
|
},
|
|
83
91
|
});
|
|
84
92
|
|
|
85
|
-
testSpace_persistTransformResult({
|
|
86
|
-
|
|
93
|
+
await testSpace_persistTransformResult({
|
|
94
|
+
respecfulTitle: sir,
|
|
95
|
+
// shortcircuitRespec: true,
|
|
87
96
|
fnGetInitialData: async () => {
|
|
88
97
|
return {
|
|
89
98
|
name: (await getUUID()).substring(0, 8),
|
|
@@ -7,20 +7,12 @@ import { getIbAndGib, getIbGibAddr, IbGibAddr } from '@ibgib/ts-gib';
|
|
|
7
7
|
import { IbGib_V1, IbGibRel8ns_V1, GIB, ROOT, isPrimitive, getGib, } from '@ibgib/ts-gib/dist/V1/index.mjs';
|
|
8
8
|
import { validateIbGibIntrinsically } from '@ibgib/ts-gib/dist/V1/validate-helper.mjs';
|
|
9
9
|
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
IbGibSpaceData, IbGibSpaceOptionsData, IbGibSpaceOptionsRel8ns,
|
|
13
|
-
IbGibSpaceOptionsIbGib, IbGibSpaceResultData, IbGibSpaceResultRel8ns,
|
|
14
|
-
IbGibSpaceResultIbGib,
|
|
15
|
-
IbGibSpaceData_Subpathed
|
|
16
|
-
} from '../space-types.mjs';
|
|
17
|
-
import { argy_ } from '../../witness-helper.mjs';
|
|
18
|
-
import { isBinary, getBinHashAndExt } from '../../../common/other/ibgib-helper.mjs';
|
|
19
|
-
import { parseSpaceIb, getSpaceIb, getSpecialIbGib, getTjpIbGib, } from '../space-helper.mjs';
|
|
10
|
+
import { isBinary, } from '../../../common/other/ibgib-helper.mjs';
|
|
11
|
+
import { parseSpaceIb, getSpaceIb, } from '../space-helper.mjs';
|
|
20
12
|
import { DEFAULT_LOCAL_SPACE_POLLING_INTERVAL_MS, IBGIB_SPACE_NAME_DEFAULT, ZERO_SPACE_ID } from '../space-constants.mjs';
|
|
21
13
|
import { GLOBAL_LOG_A_LOT } from '../../../core-constants.mjs';
|
|
22
14
|
import {
|
|
23
|
-
DeleteIbGibFileOpts, DeleteIbGibFilesResult,
|
|
15
|
+
DeleteIbGibFileOpts, DeleteIbGibFilesResult,
|
|
24
16
|
GetIbGibFileOpts,
|
|
25
17
|
GetIbGibFileResult,
|
|
26
18
|
PutIbGibFileOpts,
|
|
@@ -1,14 +1,19 @@
|
|
|
1
1
|
import { default as pathUtils } from 'path';
|
|
2
2
|
import { rm } from 'node:fs/promises';
|
|
3
3
|
|
|
4
|
+
import { firstOfAll, ifWe, ifWeMight, iReckon, lastOfAll, respecfully, respecfullyDear } from '@ibgib/helper-gib/dist/respec-gib/respec-gib.mjs';
|
|
5
|
+
const maam = `[${import.meta.url}]`, sir = maam;
|
|
4
6
|
import { delay, getUUID, } from '@ibgib/helper-gib';
|
|
5
7
|
|
|
6
8
|
import {
|
|
7
9
|
testSpace_createAndInit,
|
|
8
10
|
testSpace_persistTransformResult,
|
|
9
11
|
testSpace_PutGetDelete
|
|
10
|
-
} from '../space-
|
|
11
|
-
import {
|
|
12
|
+
} from '../space-respec-helper.mjs';
|
|
13
|
+
import {
|
|
14
|
+
getCurrentFilename, specGetBaseSubPath, specGetSpaceDescription,
|
|
15
|
+
specGetSpaceId, specGetSpaceName
|
|
16
|
+
} from '../../../spec-helper.node.respec.mjs';
|
|
12
17
|
import { NodeFilesystemSpace_V1, NodeFilesystemSpaceData_V1 } from './node-filesystem-space-v1.mjs';
|
|
13
18
|
import { IBGIB_ENCODING } from './filesystem-constants.mjs';
|
|
14
19
|
|
|
@@ -19,12 +24,8 @@ function specGetBaseDir(uuid: string): string {
|
|
|
19
24
|
return pathUtils.join(TEST_BASE_DIR_ROOT, specGetSpaceName(uuid));
|
|
20
25
|
}
|
|
21
26
|
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
beforeAll(() => {
|
|
25
|
-
|
|
26
|
-
});
|
|
27
|
-
afterAll(async () => {
|
|
27
|
+
await respecfully(sir, `[${NodeFilesystemSpace_V1.name} specs]`, async () => {
|
|
28
|
+
lastOfAll(sir, async () => {
|
|
28
29
|
// rm -rf TEST_BASE_DIR_ROOT
|
|
29
30
|
// comment this out if you want to examine generated ibgib data
|
|
30
31
|
await rm(TEST_BASE_DIR_ROOT, {
|
|
@@ -33,8 +34,9 @@ describe(`[${NodeFilesystemSpace_V1.name} specs]`, () => {
|
|
|
33
34
|
});
|
|
34
35
|
});
|
|
35
36
|
|
|
36
|
-
testSpace_createAndInit({
|
|
37
|
-
|
|
37
|
+
await testSpace_createAndInit({
|
|
38
|
+
respecfulTitle: sir,
|
|
39
|
+
// shortcircuitRespec: true,
|
|
38
40
|
fnGetInitialData: async () => {
|
|
39
41
|
const uuid = await specGetSpaceId();
|
|
40
42
|
return {
|
|
@@ -67,8 +69,9 @@ describe(`[${NodeFilesystemSpace_V1.name} specs]`, () => {
|
|
|
67
69
|
},
|
|
68
70
|
})
|
|
69
71
|
|
|
70
|
-
testSpace_PutGetDelete({
|
|
71
|
-
|
|
72
|
+
await testSpace_PutGetDelete({
|
|
73
|
+
respecfulTitle: sir,
|
|
74
|
+
// shortcircuitRespec: true,
|
|
72
75
|
fnBeforeEach: async () => {
|
|
73
76
|
|
|
74
77
|
},
|
|
@@ -105,8 +108,9 @@ describe(`[${NodeFilesystemSpace_V1.name} specs]`, () => {
|
|
|
105
108
|
},
|
|
106
109
|
});
|
|
107
110
|
|
|
108
|
-
testSpace_persistTransformResult({
|
|
109
|
-
|
|
111
|
+
await testSpace_persistTransformResult({
|
|
112
|
+
respecfulTitle: sir,
|
|
113
|
+
// shortcircuitRespec: true,
|
|
110
114
|
fnGetInitialData: async () => {
|
|
111
115
|
const uuid = await specGetSpaceId();
|
|
112
116
|
return {
|
|
@@ -1,16 +1,23 @@
|
|
|
1
|
+
import {
|
|
2
|
+
firstOfEach, firstOfAll, ifWe,
|
|
3
|
+
lastOfEach, lastOfAll,
|
|
4
|
+
ifWeMight, iReckon, respecfully
|
|
5
|
+
} from '@ibgib/helper-gib/dist/respec-gib/respec-gib.mjs';
|
|
6
|
+
const maam = `[${import.meta.url}]`, sir = maam;
|
|
1
7
|
import { getUUID, } from '@ibgib/helper-gib';
|
|
2
8
|
|
|
3
9
|
import {
|
|
4
10
|
testSpace_createAndInit,
|
|
5
11
|
testSpace_persistTransformResult,
|
|
6
12
|
testSpace_PutGetDelete
|
|
7
|
-
} from '../space-
|
|
13
|
+
} from '../space-respec-helper.mjs';
|
|
8
14
|
import { InnerSpace_V1, } from './inner-space-v1.mjs';
|
|
9
15
|
|
|
10
|
-
|
|
16
|
+
await respecfully(sir, `[${InnerSpace_V1.name} specs]`, async () => {
|
|
11
17
|
|
|
12
|
-
testSpace_createAndInit({
|
|
13
|
-
|
|
18
|
+
await testSpace_createAndInit({
|
|
19
|
+
respecfulTitle: sir,
|
|
20
|
+
// shortcircuitRespec: true,
|
|
14
21
|
fnGetInitialData: async () => {
|
|
15
22
|
return {
|
|
16
23
|
name: (await getUUID()).substring(0, 8),
|
|
@@ -25,8 +32,9 @@ describe(`[${InnerSpace_V1.name} specs]`, () => {
|
|
|
25
32
|
},
|
|
26
33
|
})
|
|
27
34
|
|
|
28
|
-
testSpace_PutGetDelete({
|
|
29
|
-
|
|
35
|
+
await testSpace_PutGetDelete({
|
|
36
|
+
respecfulTitle: sir,
|
|
37
|
+
// shortcircuitRespec: true,
|
|
30
38
|
fnGetInitialData: async () => {
|
|
31
39
|
return {
|
|
32
40
|
name: (await getUUID()).substring(0, 8),
|
|
@@ -41,8 +49,9 @@ describe(`[${InnerSpace_V1.name} specs]`, () => {
|
|
|
41
49
|
},
|
|
42
50
|
});
|
|
43
51
|
|
|
44
|
-
testSpace_persistTransformResult({
|
|
45
|
-
|
|
52
|
+
await testSpace_persistTransformResult({
|
|
53
|
+
respecfulTitle: sir,
|
|
54
|
+
// shortcircuitRespec: true,
|
|
46
55
|
fnGetInitialData: async () => {
|
|
47
56
|
return {
|
|
48
57
|
name: (await getUUID()).substring(0, 8),
|