@norskvideo/ctl-test-harness 0.1.21 → 0.1.23
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/compose-advancing.d.ts +14 -2
- package/compose-advancing.js +26 -10
- package/demo/cli.d.ts +16 -1
- package/demo/cli.js +105 -16
- package/demo/dev-loop-cli.d.ts +2 -0
- package/demo/dev-loop-cli.js +8 -0
- package/demo/dev-loop.d.ts +33 -0
- package/demo/dev-loop.js +205 -0
- package/demo/gates.js +3 -1
- package/demo/index.d.ts +6 -2
- package/demo/index.js +3 -1
- package/demo/panes.d.ts +81 -0
- package/demo/panes.js +236 -0
- package/demo/run.d.ts +96 -3
- package/demo/run.js +49 -29
- package/demo/spec.d.ts +12 -2
- package/demo/spec.js +20 -11
- package/package.json +3 -2
package/demo/spec.js
CHANGED
|
@@ -38,6 +38,21 @@ const relativePath = z
|
|
|
38
38
|
.string()
|
|
39
39
|
.min(1)
|
|
40
40
|
.refine((p) => !isAbsolute(p) && !p.startsWith("~"), { message: "must be a relative path inside the repo" });
|
|
41
|
+
const homePath = z
|
|
42
|
+
.string()
|
|
43
|
+
.min(1)
|
|
44
|
+
.refine((p) => isAbsolute(p) || p === "~" || p.startsWith("~/"), {
|
|
45
|
+
message: "must be an absolute or ~-rooted path (a checkout outside the repo)",
|
|
46
|
+
});
|
|
47
|
+
const Template = z.union([
|
|
48
|
+
z.strictObject({ name: z.string().min(1) }),
|
|
49
|
+
z.strictObject({
|
|
50
|
+
build: z.strictObject({
|
|
51
|
+
name: z.string().min(1).optional(),
|
|
52
|
+
input: z.union([z.string().min(1), z.record(z.string(), z.unknown())]),
|
|
53
|
+
}),
|
|
54
|
+
}),
|
|
55
|
+
]);
|
|
41
56
|
export const DemoSpecSchema = z
|
|
42
57
|
.strictObject({
|
|
43
58
|
product: z.string().min(1),
|
|
@@ -47,17 +62,7 @@ export const DemoSpecSchema = z
|
|
|
47
62
|
readyPath: z.string().startsWith("/").optional(),
|
|
48
63
|
}),
|
|
49
64
|
image: z.string().min(1).optional(),
|
|
50
|
-
template:
|
|
51
|
-
.union([
|
|
52
|
-
z.strictObject({ name: z.string().min(1) }),
|
|
53
|
-
z.strictObject({
|
|
54
|
-
build: z.strictObject({
|
|
55
|
-
name: z.string().min(1).optional(),
|
|
56
|
-
input: z.union([z.string().min(1), z.record(z.string(), z.unknown())]),
|
|
57
|
-
}),
|
|
58
|
-
}),
|
|
59
|
-
])
|
|
60
|
-
.optional(),
|
|
65
|
+
template: Template.optional(),
|
|
61
66
|
launch: z
|
|
62
67
|
.strictObject({
|
|
63
68
|
hardware: z.enum(["nvidia", "none"]).optional(),
|
|
@@ -105,6 +110,10 @@ export const DemoSpecSchema = z
|
|
|
105
110
|
links: z.record(z.string().min(1), relativePath).optional(),
|
|
106
111
|
dashboards: relativePath.optional(),
|
|
107
112
|
params: Params.optional(),
|
|
113
|
+
norskDir: homePath.optional(),
|
|
114
|
+
studioDir: homePath.optional(),
|
|
115
|
+
workdir: homePath.optional(),
|
|
116
|
+
template: Template.optional(),
|
|
108
117
|
})
|
|
109
118
|
.optional(),
|
|
110
119
|
})
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@norskvideo/ctl-test-harness",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.23",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"exports": {
|
|
6
6
|
".": {
|
|
@@ -59,7 +59,8 @@
|
|
|
59
59
|
"main": "./index.js",
|
|
60
60
|
"types": "./index.d.ts",
|
|
61
61
|
"bin": {
|
|
62
|
-
"ctl-demo": "./demo/cli.js"
|
|
62
|
+
"ctl-demo": "./demo/cli.js",
|
|
63
|
+
"ctl-dev-loop": "./demo/dev-loop-cli.js"
|
|
63
64
|
},
|
|
64
65
|
"dependencies": {
|
|
65
66
|
"@norskvideo/ctl-sdk": "^0.1.0",
|