Skip to content

Commit a18d802

Browse files
committed
and finish updating js-runtime fixtures' expectations too
1 parent 9f0ca8e commit a18d802

File tree

4 files changed

+109
-136
lines changed

4 files changed

+109
-136
lines changed

packages/js-runtime/test/fixtures/handler-schema/date-and-map-types.expected.ts

Lines changed: 78 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -25,16 +25,45 @@ const timedHandler = handler({
2525
Map: {
2626
type: "object",
2727
properties: {
28-
clear: { type: "object", properties: {} },
29-
delete: { type: "object", properties: {} },
30-
forEach: { type: "object", properties: {} },
31-
get: { type: "object", properties: {} },
32-
has: { type: "object", properties: {} },
33-
set: { type: "object", properties: {} },
34-
size: { type: "number" },
35-
entries: { type: "object", properties: {} },
36-
keys: { type: "object", properties: {} },
37-
values: { type: "object", properties: {} }
28+
clear: {
29+
type: "object",
30+
properties: {}
31+
},
32+
delete: {
33+
type: "object",
34+
properties: {}
35+
},
36+
forEach: {
37+
type: "object",
38+
properties: {}
39+
},
40+
get: {
41+
type: "object",
42+
properties: {}
43+
},
44+
has: {
45+
type: "object",
46+
properties: {}
47+
},
48+
set: {
49+
type: "object",
50+
properties: {}
51+
},
52+
size: {
53+
type: "number"
54+
},
55+
entries: {
56+
type: "object",
57+
properties: {}
58+
},
59+
keys: {
60+
type: "object",
61+
properties: {}
62+
},
63+
values: {
64+
type: "object",
65+
properties: {}
66+
}
3867
},
3968
required: ["clear", "delete", "forEach", "get", "has", "set", "size", "entries", "keys", "values"]
4069
}
@@ -56,16 +85,45 @@ const timedHandler = handler({
5685
Map: {
5786
type: "object",
5887
properties: {
59-
clear: { type: "object", properties: {} },
60-
delete: { type: "object", properties: {} },
61-
forEach: { type: "object", properties: {} },
62-
get: { type: "object", properties: {} },
63-
has: { type: "object", properties: {} },
64-
set: { type: "object", properties: {} },
65-
size: { type: "number" },
66-
entries: { type: "object", properties: {} },
67-
keys: { type: "object", properties: {} },
68-
values: { type: "object", properties: {} }
88+
clear: {
89+
type: "object",
90+
properties: {}
91+
},
92+
delete: {
93+
type: "object",
94+
properties: {}
95+
},
96+
forEach: {
97+
type: "object",
98+
properties: {}
99+
},
100+
get: {
101+
type: "object",
102+
properties: {}
103+
},
104+
has: {
105+
type: "object",
106+
properties: {}
107+
},
108+
set: {
109+
type: "object",
110+
properties: {}
111+
},
112+
size: {
113+
type: "number"
114+
},
115+
entries: {
116+
type: "object",
117+
properties: {}
118+
},
119+
keys: {
120+
type: "object",
121+
properties: {}
122+
},
123+
values: {
124+
type: "object",
125+
properties: {}
126+
}
69127
},
70128
required: ["clear", "delete", "forEach", "get", "has", "set", "size", "entries", "keys", "values"]
71129
}

packages/js-runtime/test/fixtures/jsx-expressions/jsx-complex-mixed.expected.tsx

Lines changed: 0 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -51,27 +51,6 @@ export default recipe({
5151
}
5252
},
5353
required: ["id", "name", "price", "active"]
54-
},
55-
State: {
56-
type: "object",
57-
properties: {
58-
items: {
59-
type: "array",
60-
items: {
61-
$ref: "#/definitions/Item"
62-
}
63-
},
64-
filter: {
65-
type: "string"
66-
},
67-
discount: {
68-
type: "number"
69-
},
70-
taxRate: {
71-
type: "number"
72-
}
73-
},
74-
required: ["items", "filter", "discount", "taxRate"]
7554
}
7655
}
7756
} as const satisfies JSONSchema, (state) => {

packages/js-runtime/test/fixtures/jsx-expressions/jsx-property-access.expected.tsx

Lines changed: 31 additions & 58 deletions
Original file line numberDiff line numberDiff line change
@@ -59,45 +59,6 @@ export default recipe({
5959
},
6060
required: ["user", "config", "items", "index", "numbers"],
6161
definitions: {
62-
User: {
63-
type: "object",
64-
properties: {
65-
name: {
66-
type: "string"
67-
},
68-
age: {
69-
type: "number"
70-
},
71-
active: {
72-
type: "boolean"
73-
},
74-
profile: {
75-
type: "object",
76-
properties: {
77-
bio: {
78-
type: "string"
79-
},
80-
location: {
81-
type: "string"
82-
},
83-
settings: {
84-
type: "object",
85-
properties: {
86-
theme: {
87-
type: "string"
88-
},
89-
notifications: {
90-
type: "boolean"
91-
}
92-
},
93-
required: ["theme", "notifications"]
94-
}
95-
},
96-
required: ["bio", "location", "settings"]
97-
}
98-
},
99-
required: ["name", "age", "active", "profile"]
100-
},
10162
Config: {
10263
type: "object",
10364
properties: {
@@ -131,32 +92,44 @@ export default recipe({
13192
},
13293
required: ["theme", "features"]
13394
},
134-
State: {
95+
User: {
13596
type: "object",
13697
properties: {
137-
user: {
138-
$ref: "#/definitions/User"
139-
},
140-
config: {
141-
$ref: "#/definitions/Config"
142-
},
143-
items: {
144-
type: "array",
145-
items: {
146-
type: "string"
147-
}
98+
name: {
99+
type: "string"
148100
},
149-
index: {
101+
age: {
150102
type: "number"
151103
},
152-
numbers: {
153-
type: "array",
154-
items: {
155-
type: "number"
156-
}
104+
active: {
105+
type: "boolean"
106+
},
107+
profile: {
108+
type: "object",
109+
properties: {
110+
bio: {
111+
type: "string"
112+
},
113+
location: {
114+
type: "string"
115+
},
116+
settings: {
117+
type: "object",
118+
properties: {
119+
theme: {
120+
type: "string"
121+
},
122+
notifications: {
123+
type: "boolean"
124+
}
125+
},
126+
required: ["theme", "notifications"]
127+
}
128+
},
129+
required: ["bio", "location", "settings"]
157130
}
158131
},
159-
required: ["user", "config", "items", "index", "numbers"]
132+
required: ["name", "age", "active", "profile"]
160133
}
161134
}
162135
} as const satisfies JSONSchema, (state) => {

packages/js-runtime/test/fixtures/schema-transform/recipe-with-types.expected.tsx

Lines changed: 0 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -43,23 +43,6 @@ const inputSchema = {
4343
}
4444
},
4545
required: ["text"]
46-
},
47-
InputSchemaInterface: {
48-
type: "object",
49-
properties: {
50-
title: {
51-
type: "string",
52-
default: "untitled"
53-
},
54-
items: {
55-
type: "array",
56-
items: {
57-
$ref: "#/definitions/Item"
58-
},
59-
default: []
60-
}
61-
},
62-
required: ["title", "items"]
6346
}
6447
}
6548
} as const satisfies JSONSchema;
@@ -93,26 +76,6 @@ const outputSchema = {
9376
}
9477
},
9578
required: ["text"]
96-
},
97-
OutputSchemaInterface: {
98-
type: "object",
99-
properties: {
100-
items_count: {
101-
type: "number"
102-
},
103-
title: {
104-
type: "string",
105-
default: "untitled"
106-
},
107-
items: {
108-
type: "array",
109-
items: {
110-
$ref: "#/definitions/Item"
111-
},
112-
default: []
113-
}
114-
},
115-
required: ["items_count", "title", "items"]
11679
}
11780
}
11881
} as const satisfies JSONSchema;

0 commit comments

Comments
 (0)