@kumwe/studio-testkit 0.1.0-alpha.5 → 0.1.0-alpha.7

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.
Files changed (81) hide show
  1. package/README.md +28 -2
  2. package/corpus-manifest.json +760 -0
  3. package/dist/host-testbed.d.ts.map +1 -1
  4. package/dist/host-testbed.js +131 -0
  5. package/dist/host-testbed.js.map +1 -1
  6. package/dist/http-host-adapter.d.ts.map +1 -1
  7. package/dist/http-host-adapter.js +15 -0
  8. package/dist/http-host-adapter.js.map +1 -1
  9. package/fixtures/design-vocabulary.example.json +85 -0
  10. package/fixtures/field-adapter.example.json +27 -0
  11. package/fixtures/host-capabilities.example.json +9 -3
  12. package/fixtures/host-operations.example.json +270 -0
  13. package/fixtures/inspector.example.json +17 -0
  14. package/fixtures/media-upload-grant.example.json +14 -0
  15. package/fixtures/migration.example.json +22 -0
  16. package/fixtures/studio-config.example.json +1 -1
  17. package/invalid/blueprint.revoking-slot-marker.json +57 -0
  18. package/invalid/design-vocabulary.unknown-control-kind.json +38 -0
  19. package/invalid/inspector.empty-block-types.json +20 -0
  20. package/invalid/media-upload-grant.insecure-url.json +14 -0
  21. package/invalid/migration.empty-artifact-kinds.json +22 -0
  22. package/invalid/preview-message.activated-unknown-interaction.json +16 -0
  23. package/invalid/preview-message.viewport-role-and-size.json +16 -0
  24. package/package.json +6 -4
  25. package/vectors/canonical/array-order.json +13 -0
  26. package/vectors/canonical/control-characters.json +13 -0
  27. package/vectors/canonical/depth-exceeded.json +21 -0
  28. package/vectors/canonical/empty-containers.json +14 -0
  29. package/vectors/canonical/forbidden-member.json +14 -0
  30. package/vectors/canonical/member-order.json +16 -0
  31. package/vectors/canonical/negative-zero.json +13 -0
  32. package/vectors/canonical/nested-order.json +19 -0
  33. package/vectors/canonical/non-ascii.json +13 -0
  34. package/vectors/canonical/numbers.json +16 -0
  35. package/vectors/canonical/string-escapes.json +13 -0
  36. package/vectors/canonical/surrogate-pair.json +13 -0
  37. package/vectors/command/mode.blueprint.set-field-value.error.json +76 -0
  38. package/vectors/command/mode.blueprint.set-property.json +131 -0
  39. package/vectors/command/mode.content.insert-node.error.json +88 -0
  40. package/vectors/command/mode.hybrid.batch-atomic.error.json +158 -0
  41. package/vectors/command/mode.hybrid.insert-allowed.json +263 -0
  42. package/vectors/command/mode.hybrid.insert-designer-slot.error.json +145 -0
  43. package/vectors/command/mode.hybrid.insert-disallowed-type.error.json +145 -0
  44. package/vectors/command/mode.hybrid.insert-roots.error.json +143 -0
  45. package/vectors/command/mode.hybrid.remove-locked.error.json +130 -0
  46. package/vectors/command/mode.hybrid.reorder-with-locked.json +239 -0
  47. package/vectors/command/mode.hybrid.set-property.error.json +132 -0
  48. package/vectors/command/mode.hybrid.slot-marker-disallowed.error.json +125 -0
  49. package/vectors/command/mode.hybrid.slot-marker-insert.json +223 -0
  50. package/vectors/command/mode.hybrid.slot-marker-other-slot.error.json +125 -0
  51. package/vectors/command/mode.model.remove-node.error.json +75 -0
  52. package/vectors/command/mode.read-only.set-property.error.json +77 -0
  53. package/vectors/host/artifact.dependencies.result.json +35 -0
  54. package/vectors/host/artifact.load.stored.json +36 -0
  55. package/vectors/host/artifact.load.unknown.error.json +37 -0
  56. package/vectors/host/artifact.publish.accepted.json +37 -0
  57. package/vectors/host/artifact.publish.forbidden.error.json +37 -0
  58. package/vectors/host/artifact.publish.stale.error.json +38 -0
  59. package/vectors/host/artifact.save.accepted.json +38 -0
  60. package/vectors/host/artifact.save.forbidden.error.json +38 -0
  61. package/vectors/host/artifact.save.stale.error.json +39 -0
  62. package/vectors/host/artifact.unpublish.stale.error.json +38 -0
  63. package/vectors/host/envelope.malformed-context.error.json +36 -0
  64. package/vectors/host/envelope.protocol-version.error.json +36 -0
  65. package/vectors/host/envelope.stale-generation.error.json +36 -0
  66. package/vectors/host/localization.messages.unknown-locale.error.json +36 -0
  67. package/vectors/host/media.abort-upload.unknown.error.json +35 -0
  68. package/vectors/host/media.authorize-upload.granted.json +37 -0
  69. package/vectors/host/media.authorize-upload.path-filename.error.json +39 -0
  70. package/vectors/host/media.authorize-upload.too-large.error.json +38 -0
  71. package/vectors/host/media.complete-upload.unknown.error.json +36 -0
  72. package/vectors/host/media.get.unknown.json +34 -0
  73. package/vectors/host/media.import-external.private-host.error.json +36 -0
  74. package/vectors/host/media.list.cursor.error.json +36 -0
  75. package/vectors/host/media.list.limit.error.json +35 -0
  76. package/vectors/host/media.upload-status.unknown.error.json +35 -0
  77. package/vectors/host/permission.explain.withheld.json +34 -0
  78. package/vectors/host/permission.refresh.snapshot.json +31 -0
  79. package/vectors/host/recovery.load.absent.json +31 -0
  80. package/vectors/host/telemetry.emit.accepted.json +37 -0
  81. package/vectors/host/telemetry.emit.non-primitive.error.json +40 -0
@@ -0,0 +1,223 @@
1
+ {
2
+ "contractVersion": "0.1-draft",
3
+ "kind": "command-vector",
4
+ "id": "vector.command-vector.mode.hybrid.slot-marker-insert",
5
+ "description": "A per-slot composition marker makes one named slot of a non-structural node composable.",
6
+ "mode": "hybrid",
7
+ "initial": {
8
+ "contractVersion": "0.1-draft",
9
+ "dependencyLock": {
10
+ "blocks": [
11
+ {
12
+ "revision": "block-r1",
13
+ "type": "studio.vector/card",
14
+ "version": "1.0.0"
15
+ },
16
+ {
17
+ "revision": "block-r1",
18
+ "type": "studio.vector/section",
19
+ "version": "1.0.0"
20
+ }
21
+ ],
22
+ "theme": {
23
+ "id": "studio.vector/theme",
24
+ "revision": "theme-r1",
25
+ "version": "1.0.0"
26
+ }
27
+ },
28
+ "id": "vector.blueprint",
29
+ "kind": "blueprint",
30
+ "label": {
31
+ "defaultMessage": "Vector Blueprint",
32
+ "key": "studio.vector/blueprint"
33
+ },
34
+ "model": {
35
+ "id": "studio.vector/model",
36
+ "revision": "model-r1",
37
+ "version": "1.0.0"
38
+ },
39
+ "owner": {
40
+ "id": "studio.vector/suite",
41
+ "version": "0.1.0-alpha.0"
42
+ },
43
+ "revision": "blueprint-r1",
44
+ "roots": [
45
+ {
46
+ "authoring": {
47
+ "mode": "designer",
48
+ "slots": {
49
+ "inlay": {
50
+ "allowedBlocks": ["studio.vector/card"],
51
+ "composable": true
52
+ }
53
+ }
54
+ },
55
+ "bindings": {},
56
+ "id": "panel",
57
+ "properties": {},
58
+ "slots": {
59
+ "inlay": [
60
+ {
61
+ "authoring": {
62
+ "mode": "content"
63
+ },
64
+ "bindings": {},
65
+ "id": "card-1",
66
+ "properties": {
67
+ "title": "First"
68
+ },
69
+ "slots": {},
70
+ "type": "studio.vector/card",
71
+ "version": "1.0.0"
72
+ }
73
+ ],
74
+ "trim": [
75
+ {
76
+ "authoring": {
77
+ "mode": "designer"
78
+ },
79
+ "bindings": {},
80
+ "id": "fixed",
81
+ "properties": {},
82
+ "slots": {},
83
+ "type": "studio.vector/section",
84
+ "version": "1.0.0"
85
+ }
86
+ ]
87
+ },
88
+ "type": "studio.vector/section",
89
+ "version": "1.0.0"
90
+ }
91
+ ],
92
+ "status": "draft",
93
+ "version": "1.0.0"
94
+ },
95
+ "command": {
96
+ "artifactId": "vector.blueprint",
97
+ "baseStateVersion": 0,
98
+ "contractVersion": "0.1-draft",
99
+ "id": "vector.command.mode.hybrid.slot-marker-insert",
100
+ "kind": "command",
101
+ "payload": {
102
+ "destination": {
103
+ "parentNodeId": "panel",
104
+ "position": 1,
105
+ "slot": "inlay"
106
+ },
107
+ "node": {
108
+ "authoring": {
109
+ "mode": "content"
110
+ },
111
+ "bindings": {},
112
+ "id": "card-2",
113
+ "properties": {},
114
+ "slots": {},
115
+ "type": "studio.vector/card",
116
+ "version": "1.0.0"
117
+ }
118
+ },
119
+ "sessionGeneration": "session-r1",
120
+ "type": "studio.command/insert-node"
121
+ },
122
+ "expect": {
123
+ "document": {
124
+ "contractVersion": "0.1-draft",
125
+ "dependencyLock": {
126
+ "blocks": [
127
+ {
128
+ "revision": "block-r1",
129
+ "type": "studio.vector/card",
130
+ "version": "1.0.0"
131
+ },
132
+ {
133
+ "revision": "block-r1",
134
+ "type": "studio.vector/section",
135
+ "version": "1.0.0"
136
+ }
137
+ ],
138
+ "theme": {
139
+ "id": "studio.vector/theme",
140
+ "revision": "theme-r1",
141
+ "version": "1.0.0"
142
+ }
143
+ },
144
+ "id": "vector.blueprint",
145
+ "kind": "blueprint",
146
+ "label": {
147
+ "defaultMessage": "Vector Blueprint",
148
+ "key": "studio.vector/blueprint"
149
+ },
150
+ "model": {
151
+ "id": "studio.vector/model",
152
+ "revision": "model-r1",
153
+ "version": "1.0.0"
154
+ },
155
+ "owner": {
156
+ "id": "studio.vector/suite",
157
+ "version": "0.1.0-alpha.0"
158
+ },
159
+ "revision": "blueprint-r1",
160
+ "roots": [
161
+ {
162
+ "authoring": {
163
+ "mode": "designer",
164
+ "slots": {
165
+ "inlay": {
166
+ "allowedBlocks": ["studio.vector/card"],
167
+ "composable": true
168
+ }
169
+ }
170
+ },
171
+ "bindings": {},
172
+ "id": "panel",
173
+ "properties": {},
174
+ "slots": {
175
+ "inlay": [
176
+ {
177
+ "authoring": {
178
+ "mode": "content"
179
+ },
180
+ "bindings": {},
181
+ "id": "card-1",
182
+ "properties": {
183
+ "title": "First"
184
+ },
185
+ "slots": {},
186
+ "type": "studio.vector/card",
187
+ "version": "1.0.0"
188
+ },
189
+ {
190
+ "authoring": {
191
+ "mode": "content"
192
+ },
193
+ "bindings": {},
194
+ "id": "card-2",
195
+ "properties": {},
196
+ "slots": {},
197
+ "type": "studio.vector/card",
198
+ "version": "1.0.0"
199
+ }
200
+ ],
201
+ "trim": [
202
+ {
203
+ "authoring": {
204
+ "mode": "designer"
205
+ },
206
+ "bindings": {},
207
+ "id": "fixed",
208
+ "properties": {},
209
+ "slots": {},
210
+ "type": "studio.vector/section",
211
+ "version": "1.0.0"
212
+ }
213
+ ]
214
+ },
215
+ "type": "studio.vector/section",
216
+ "version": "1.0.0"
217
+ }
218
+ ],
219
+ "status": "draft",
220
+ "version": "1.0.0"
221
+ }
222
+ }
223
+ }
@@ -0,0 +1,125 @@
1
+ {
2
+ "contractVersion": "0.1-draft",
3
+ "kind": "command-vector",
4
+ "id": "vector.command-vector.mode.hybrid.slot-marker-other-slot",
5
+ "description": "The marker grants composability slot by slot; an unmarked sibling slot stays out of bounds.",
6
+ "mode": "hybrid",
7
+ "initial": {
8
+ "contractVersion": "0.1-draft",
9
+ "dependencyLock": {
10
+ "blocks": [
11
+ {
12
+ "revision": "block-r1",
13
+ "type": "studio.vector/card",
14
+ "version": "1.0.0"
15
+ },
16
+ {
17
+ "revision": "block-r1",
18
+ "type": "studio.vector/section",
19
+ "version": "1.0.0"
20
+ }
21
+ ],
22
+ "theme": {
23
+ "id": "studio.vector/theme",
24
+ "revision": "theme-r1",
25
+ "version": "1.0.0"
26
+ }
27
+ },
28
+ "id": "vector.blueprint",
29
+ "kind": "blueprint",
30
+ "label": {
31
+ "defaultMessage": "Vector Blueprint",
32
+ "key": "studio.vector/blueprint"
33
+ },
34
+ "model": {
35
+ "id": "studio.vector/model",
36
+ "revision": "model-r1",
37
+ "version": "1.0.0"
38
+ },
39
+ "owner": {
40
+ "id": "studio.vector/suite",
41
+ "version": "0.1.0-alpha.0"
42
+ },
43
+ "revision": "blueprint-r1",
44
+ "roots": [
45
+ {
46
+ "authoring": {
47
+ "mode": "designer",
48
+ "slots": {
49
+ "inlay": {
50
+ "allowedBlocks": ["studio.vector/card"],
51
+ "composable": true
52
+ }
53
+ }
54
+ },
55
+ "bindings": {},
56
+ "id": "panel",
57
+ "properties": {},
58
+ "slots": {
59
+ "inlay": [
60
+ {
61
+ "authoring": {
62
+ "mode": "content"
63
+ },
64
+ "bindings": {},
65
+ "id": "card-1",
66
+ "properties": {
67
+ "title": "First"
68
+ },
69
+ "slots": {},
70
+ "type": "studio.vector/card",
71
+ "version": "1.0.0"
72
+ }
73
+ ],
74
+ "trim": [
75
+ {
76
+ "authoring": {
77
+ "mode": "designer"
78
+ },
79
+ "bindings": {},
80
+ "id": "fixed",
81
+ "properties": {},
82
+ "slots": {},
83
+ "type": "studio.vector/section",
84
+ "version": "1.0.0"
85
+ }
86
+ ]
87
+ },
88
+ "type": "studio.vector/section",
89
+ "version": "1.0.0"
90
+ }
91
+ ],
92
+ "status": "draft",
93
+ "version": "1.0.0"
94
+ },
95
+ "command": {
96
+ "artifactId": "vector.blueprint",
97
+ "baseStateVersion": 0,
98
+ "contractVersion": "0.1-draft",
99
+ "id": "vector.command.mode.hybrid.slot-marker-other-slot",
100
+ "kind": "command",
101
+ "payload": {
102
+ "destination": {
103
+ "parentNodeId": "panel",
104
+ "position": 0,
105
+ "slot": "trim"
106
+ },
107
+ "node": {
108
+ "authoring": {
109
+ "mode": "content"
110
+ },
111
+ "bindings": {},
112
+ "id": "card-2",
113
+ "properties": {},
114
+ "slots": {},
115
+ "type": "studio.vector/card",
116
+ "version": "1.0.0"
117
+ }
118
+ },
119
+ "sessionGeneration": "session-r1",
120
+ "type": "studio.command/insert-node"
121
+ },
122
+ "expect": {
123
+ "errorCode": "mode-forbidden"
124
+ }
125
+ }
@@ -0,0 +1,75 @@
1
+ {
2
+ "contractVersion": "0.1-draft",
3
+ "kind": "command-vector",
4
+ "id": "vector.command-vector.mode.model.remove-node",
5
+ "description": "A model-mode session permits only content-model commands; structure commands are mode-forbidden.",
6
+ "mode": "model",
7
+ "initial": {
8
+ "contractVersion": "0.1-draft",
9
+ "dependencyLock": {
10
+ "blocks": [
11
+ {
12
+ "revision": "block-r1",
13
+ "type": "studio.vector/section",
14
+ "version": "1.0.0"
15
+ },
16
+ {
17
+ "revision": "block-r1",
18
+ "type": "studio.vector/text",
19
+ "version": "1.0.0"
20
+ }
21
+ ],
22
+ "theme": {
23
+ "id": "studio.vector/theme",
24
+ "revision": "theme-r1",
25
+ "version": "1.0.0"
26
+ }
27
+ },
28
+ "id": "vector.blueprint",
29
+ "kind": "blueprint",
30
+ "label": {
31
+ "defaultMessage": "Vector Blueprint",
32
+ "key": "studio.vector/blueprint"
33
+ },
34
+ "model": {
35
+ "id": "studio.vector/model",
36
+ "revision": "model-r1",
37
+ "version": "1.0.0"
38
+ },
39
+ "owner": {
40
+ "id": "studio.vector/suite",
41
+ "version": "0.1.0-alpha.0"
42
+ },
43
+ "revision": "blueprint-r1",
44
+ "roots": [
45
+ {
46
+ "authoring": {
47
+ "mode": "designer"
48
+ },
49
+ "bindings": {},
50
+ "id": "text-a",
51
+ "properties": {},
52
+ "slots": {},
53
+ "type": "studio.vector/text",
54
+ "version": "1.0.0"
55
+ }
56
+ ],
57
+ "status": "draft",
58
+ "version": "1.0.0"
59
+ },
60
+ "command": {
61
+ "artifactId": "vector.blueprint",
62
+ "baseStateVersion": 0,
63
+ "contractVersion": "0.1-draft",
64
+ "id": "vector.command.mode.model.remove-node",
65
+ "kind": "command",
66
+ "payload": {
67
+ "nodeId": "text-a"
68
+ },
69
+ "sessionGeneration": "session-r1",
70
+ "type": "studio.command/remove-node"
71
+ },
72
+ "expect": {
73
+ "errorCode": "mode-forbidden"
74
+ }
75
+ }
@@ -0,0 +1,77 @@
1
+ {
2
+ "contractVersion": "0.1-draft",
3
+ "kind": "command-vector",
4
+ "id": "vector.command-vector.mode.read-only.set-property",
5
+ "description": "A read-only session never applies a persistent command; the rejection precedes the mode table.",
6
+ "mode": "read-only",
7
+ "initial": {
8
+ "contractVersion": "0.1-draft",
9
+ "dependencyLock": {
10
+ "blocks": [
11
+ {
12
+ "revision": "block-r1",
13
+ "type": "studio.vector/section",
14
+ "version": "1.0.0"
15
+ },
16
+ {
17
+ "revision": "block-r1",
18
+ "type": "studio.vector/text",
19
+ "version": "1.0.0"
20
+ }
21
+ ],
22
+ "theme": {
23
+ "id": "studio.vector/theme",
24
+ "revision": "theme-r1",
25
+ "version": "1.0.0"
26
+ }
27
+ },
28
+ "id": "vector.blueprint",
29
+ "kind": "blueprint",
30
+ "label": {
31
+ "defaultMessage": "Vector Blueprint",
32
+ "key": "studio.vector/blueprint"
33
+ },
34
+ "model": {
35
+ "id": "studio.vector/model",
36
+ "revision": "model-r1",
37
+ "version": "1.0.0"
38
+ },
39
+ "owner": {
40
+ "id": "studio.vector/suite",
41
+ "version": "0.1.0-alpha.0"
42
+ },
43
+ "revision": "blueprint-r1",
44
+ "roots": [
45
+ {
46
+ "authoring": {
47
+ "mode": "designer"
48
+ },
49
+ "bindings": {},
50
+ "id": "text-a",
51
+ "properties": {},
52
+ "slots": {},
53
+ "type": "studio.vector/text",
54
+ "version": "1.0.0"
55
+ }
56
+ ],
57
+ "status": "draft",
58
+ "version": "1.0.0"
59
+ },
60
+ "command": {
61
+ "artifactId": "vector.blueprint",
62
+ "baseStateVersion": 0,
63
+ "contractVersion": "0.1-draft",
64
+ "id": "vector.command.mode.read-only.set-property",
65
+ "kind": "command",
66
+ "payload": {
67
+ "nodeId": "text-a",
68
+ "property": "text",
69
+ "value": "Hello"
70
+ },
71
+ "sessionGeneration": "session-r1",
72
+ "type": "studio.command/set-property"
73
+ },
74
+ "expect": {
75
+ "errorCode": "read-only-session"
76
+ }
77
+ }
@@ -0,0 +1,35 @@
1
+ {
2
+ "contractVersion": "0.1-draft",
3
+ "kind": "host-vector",
4
+ "id": "vector.host-vector.artifact.dependencies",
5
+ "description": "Dependency inspection answers with the authorized reference list.",
6
+ "profile": "studio.profile/host-baseline",
7
+ "port": "artifact",
8
+ "operation": "dependencies",
9
+ "given": {
10
+ "artifacts": [
11
+ {
12
+ "id": "vector.blueprint",
13
+ "kind": "blueprint",
14
+ "revision": "vector.blueprint-r1"
15
+ }
16
+ ],
17
+ "permissions": ["studio.permission/publish", "studio.permission/save"],
18
+ "sessionGeneration": "session-r1"
19
+ },
20
+ "context": {
21
+ "operationId": "studio.host/operation",
22
+ "protocolVersion": "0.1.0-draft.1",
23
+ "requestId": "requests/vector-1",
24
+ "resourceContextKey": "contexts/vector",
25
+ "sessionGeneration": "session-r1"
26
+ },
27
+ "argument": {
28
+ "id": "vector.blueprint",
29
+ "version": "1.0.0"
30
+ },
31
+ "expect": {
32
+ "outcome": "result",
33
+ "value": "artifact-references"
34
+ }
35
+ }
@@ -0,0 +1,36 @@
1
+ {
2
+ "contractVersion": "0.1-draft",
3
+ "kind": "host-vector",
4
+ "id": "vector.host-vector.artifact.load.stored",
5
+ "description": "Loading a stored artifact returns it with the revision it is stored at.",
6
+ "profile": "studio.profile/host-baseline",
7
+ "port": "artifact",
8
+ "operation": "load",
9
+ "given": {
10
+ "artifacts": [
11
+ {
12
+ "id": "vector.blueprint",
13
+ "kind": "blueprint",
14
+ "revision": "vector.blueprint-r1"
15
+ }
16
+ ],
17
+ "permissions": ["studio.permission/publish", "studio.permission/save"],
18
+ "sessionGeneration": "session-r1"
19
+ },
20
+ "context": {
21
+ "operationId": "studio.host/operation",
22
+ "protocolVersion": "0.1.0-draft.1",
23
+ "requestId": "requests/vector-1",
24
+ "resourceContextKey": "contexts/vector",
25
+ "sessionGeneration": "session-r1"
26
+ },
27
+ "argument": {
28
+ "id": "vector.blueprint",
29
+ "version": "1.0.0"
30
+ },
31
+ "expect": {
32
+ "outcome": "result",
33
+ "revision": "vector.blueprint-r1",
34
+ "value": "artifact"
35
+ }
36
+ }
@@ -0,0 +1,37 @@
1
+ {
2
+ "contractVersion": "0.1-draft",
3
+ "kind": "host-vector",
4
+ "id": "vector.host-vector.artifact.load.unknown",
5
+ "description": "An unknown artifact identifier is refused as not-found without disclosing whether it exists.",
6
+ "profile": "studio.profile/host-baseline",
7
+ "port": "artifact",
8
+ "operation": "load",
9
+ "given": {
10
+ "artifacts": [
11
+ {
12
+ "id": "vector.blueprint",
13
+ "kind": "blueprint",
14
+ "revision": "vector.blueprint-r1"
15
+ }
16
+ ],
17
+ "permissions": ["studio.permission/publish", "studio.permission/save"],
18
+ "sessionGeneration": "session-r1"
19
+ },
20
+ "context": {
21
+ "operationId": "studio.host/operation",
22
+ "protocolVersion": "0.1.0-draft.1",
23
+ "requestId": "requests/vector-1",
24
+ "resourceContextKey": "contexts/vector",
25
+ "sessionGeneration": "session-r1"
26
+ },
27
+ "argument": {
28
+ "id": "vector.absent",
29
+ "version": "1.0.0"
30
+ },
31
+ "expect": {
32
+ "outcome": "error",
33
+ "category": "not-found",
34
+ "retryable": false,
35
+ "messageMustNotContain": ["vector.absent"]
36
+ }
37
+ }
@@ -0,0 +1,37 @@
1
+ {
2
+ "contractVersion": "0.1-draft",
3
+ "kind": "host-vector",
4
+ "id": "vector.host-vector.artifact.publish.accepted",
5
+ "description": "Publishing under the current revision is accepted and advances the revision.",
6
+ "profile": "studio.profile/host-baseline",
7
+ "port": "artifact",
8
+ "operation": "publish",
9
+ "given": {
10
+ "artifacts": [
11
+ {
12
+ "id": "vector.blueprint",
13
+ "kind": "blueprint",
14
+ "revision": "vector.blueprint-r1"
15
+ }
16
+ ],
17
+ "permissions": ["studio.permission/publish", "studio.permission/save"],
18
+ "sessionGeneration": "session-r1"
19
+ },
20
+ "context": {
21
+ "operationId": "studio.host/operation",
22
+ "protocolVersion": "0.1.0-draft.1",
23
+ "requestId": "requests/vector-1",
24
+ "resourceContextKey": "contexts/vector",
25
+ "sessionGeneration": "session-r1",
26
+ "expectedRevision": "vector.blueprint-r1"
27
+ },
28
+ "argument": {
29
+ "id": "vector.blueprint",
30
+ "version": "1.0.0"
31
+ },
32
+ "expect": {
33
+ "outcome": "result",
34
+ "revisionAdvances": true,
35
+ "value": "null"
36
+ }
37
+ }
@@ -0,0 +1,37 @@
1
+ {
2
+ "contractVersion": "0.1-draft",
3
+ "kind": "host-vector",
4
+ "id": "vector.host-vector.artifact.publish.forbidden",
5
+ "description": "Publication authority is distinct from save authority: holding one never grants the other.",
6
+ "profile": "studio.profile/host-baseline",
7
+ "port": "artifact",
8
+ "operation": "publish",
9
+ "given": {
10
+ "artifacts": [
11
+ {
12
+ "id": "vector.blueprint",
13
+ "kind": "blueprint",
14
+ "revision": "vector.blueprint-r1"
15
+ }
16
+ ],
17
+ "permissions": ["studio.permission/save"],
18
+ "sessionGeneration": "session-r1"
19
+ },
20
+ "context": {
21
+ "operationId": "studio.operation/artifact.publish",
22
+ "protocolVersion": "0.1.0-draft.1",
23
+ "requestId": "requests/vector-1",
24
+ "resourceContextKey": "contexts/vector",
25
+ "sessionGeneration": "session-r1",
26
+ "expectedRevision": "vector.blueprint-r1"
27
+ },
28
+ "argument": {
29
+ "id": "vector.blueprint",
30
+ "version": "1.0.0"
31
+ },
32
+ "expect": {
33
+ "outcome": "error",
34
+ "category": "forbidden",
35
+ "retryable": false
36
+ }
37
+ }