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:
@@ -75,7 +75,6 @@ describe('createExtensionOverrides', () => {
|
||||
"id": "a",
|
||||
"inputs": {},
|
||||
"output": {},
|
||||
"override": [Function],
|
||||
"toString": [Function],
|
||||
"version": "v1",
|
||||
},
|
||||
@@ -91,7 +90,6 @@ describe('createExtensionOverrides', () => {
|
||||
"id": "b",
|
||||
"inputs": {},
|
||||
"output": {},
|
||||
"override": [Function],
|
||||
"toString": [Function],
|
||||
"version": "v1",
|
||||
},
|
||||
@@ -107,7 +105,6 @@ describe('createExtensionOverrides', () => {
|
||||
"id": "k:c/n",
|
||||
"inputs": {},
|
||||
"output": {},
|
||||
"override": [Function],
|
||||
"toString": [Function],
|
||||
"version": "v1",
|
||||
},
|
||||
|
||||
@@ -23,6 +23,7 @@ describe('resolveExtensionDefinition', () => {
|
||||
version: 'v2',
|
||||
attachTo: { id: '', input: '' },
|
||||
disabled: false,
|
||||
override: () => ({} as ExtensionDefinition<unknown>),
|
||||
};
|
||||
|
||||
it.each([
|
||||
@@ -63,6 +64,7 @@ describe('old resolveExtensionDefinition', () => {
|
||||
version: 'v1',
|
||||
attachTo: { id: '', input: '' },
|
||||
disabled: false,
|
||||
override: () => ({} as ExtensionDefinition<unknown>),
|
||||
};
|
||||
|
||||
it.each([
|
||||
|
||||
@@ -100,7 +100,13 @@ export function resolveExtensionDefinition<TConfig, TConfigInput>(
|
||||
context?: { namespace?: string },
|
||||
): Extension<TConfig, TConfigInput> {
|
||||
const internalDefinition = toInternalExtensionDefinition(definition);
|
||||
const { name, kind, namespace: _, ...rest } = internalDefinition;
|
||||
const {
|
||||
name,
|
||||
kind,
|
||||
namespace: _skip1,
|
||||
override: _skip2,
|
||||
...rest
|
||||
} = internalDefinition;
|
||||
const namespace = internalDefinition.namespace ?? context?.namespace;
|
||||
|
||||
const namePart =
|
||||
|
||||
Reference in New Issue
Block a user