chore: fix tests and update api-reports

Co-authored-by: Patrik Oldsberg <poldsberg@gmail.com>
Co-authored-by: Fredrik Adelöw <freben@users.noreply.github.com>
Co-authored-by: Camila Belo <camilaibs@users.noreply.github.com>

Signed-off-by: blam <ben@blam.sh>
This commit is contained in:
blam
2024-08-07 17:30:47 +02:00
parent 9fdbbd0889
commit feb5fc73c3
13 changed files with 146 additions and 93 deletions
@@ -68,7 +68,7 @@ function makeNode<TConfig, TConfigInput>(
function makeInstanceWithId<TConfig, TConfigInput>(
extension: Extension<TConfig, TConfigInput>,
config?: TConfig,
config?: TConfigInput,
): AppNode {
const node = makeNode(extension, { config });
return {
@@ -640,12 +640,12 @@ describe('instantiateAppNodeTree', () => {
name: 'test',
attachTo: { id: 'ignored', input: 'ignored' },
output: [testDataRef, otherDataRef.optional()],
configSchema: createSchemaFromZod(z =>
z.object({
output: z.string().default('test'),
other: z.number().optional(),
}),
),
config: {
schema: {
output: z => z.string().default('test'),
other: z => z.number().optional(),
},
},
factory({ config }) {
return [
testDataRef(config.output),
@@ -48,6 +48,7 @@ function makeExtDef(
name,
attachTo: { id: attachId, input: 'default' },
disabled: status === 'disabled',
override: () => ({} as ExtensionDefinition<unknown>),
} as ExtensionDefinition<unknown>;
}