@@ -10,7 +10,7 @@ import {
10
10
} from "./__fixtures__/WrapperComponent" ;
11
11
12
12
import {
13
- getSliceZoneComponents ,
13
+ defineSliceZoneComponents ,
14
14
SliceComponentType ,
15
15
SliceZoneImpl ,
16
16
SliceZoneResolver ,
@@ -44,7 +44,7 @@ test("renders slice zone with correct component mapping from components", async
44
44
{ slice_type : "bar" } ,
45
45
{ slice_type : "baz" } ,
46
46
] ,
47
- components : getSliceZoneComponents ( {
47
+ components : defineSliceZoneComponents ( {
48
48
foo : Foo ,
49
49
bar : defineAsyncComponent (
50
50
( ) => new Promise < SliceComponentType > ( ( res ) => res ( Bar ) ) ,
@@ -91,7 +91,7 @@ test("renders slice zone with correct component mapping from resolver", async (t
91
91
{ slice_type : "baz" } ,
92
92
] ,
93
93
resolver : ( ( { sliceName } ) => {
94
- const components = getSliceZoneComponents ( {
94
+ const components = defineSliceZoneComponents ( {
95
95
foo : Foo ,
96
96
bar : defineAsyncComponent (
97
97
( ) => new Promise < SliceComponentType > ( ( res ) => res ( Bar ) ) ,
@@ -134,7 +134,7 @@ test("provides context to each slice", (t) => {
134
134
const wrapper = mount ( SliceZoneImpl , {
135
135
props : {
136
136
slices : [ { slice_type : "foo" } , { slice_type : "bar" } ] ,
137
- components : getSliceZoneComponents ( {
137
+ components : defineSliceZoneComponents ( {
138
138
foo : Foo ,
139
139
bar : Bar ,
140
140
} ) ,
@@ -157,7 +157,7 @@ test("renders TODO component if component mapping is missing", (t) => {
157
157
const wrapper = mount ( SliceZoneImpl , {
158
158
props : {
159
159
slices : [ { slice_type : "foo" } , { slice_type : "bar" } ] ,
160
- components : getSliceZoneComponents ( {
160
+ components : defineSliceZoneComponents ( {
161
161
foo : Foo ,
162
162
} ) ,
163
163
} ,
@@ -196,7 +196,7 @@ test("renders plugin provided TODO component if component mapping is missing", (
196
196
const wrapper = mount ( SliceZoneImpl , {
197
197
props : {
198
198
slices : [ { slice_type : "foo" } , { slice_type : "bar" } ] ,
199
- components : getSliceZoneComponents ( {
199
+ components : defineSliceZoneComponents ( {
200
200
foo : Foo ,
201
201
} ) ,
202
202
} ,
@@ -234,7 +234,7 @@ test("renders provided TODO component over plugin provided if component mapping
234
234
const wrapper = mount ( SliceZoneImpl , {
235
235
props : {
236
236
slices : [ { slice_type : "foo" } , { slice_type : "bar" } ] ,
237
- components : getSliceZoneComponents ( {
237
+ components : defineSliceZoneComponents ( {
238
238
foo : Foo ,
239
239
} ) ,
240
240
defaultComponent : markRaw ( Baz ) ,
@@ -270,7 +270,7 @@ test("wraps output with provided wrapper tag", (t) => {
270
270
const wrapper = mount ( SliceZoneImpl , {
271
271
props : {
272
272
slices : [ { slice_type : "foo" } , { slice_type : "bar" } ] ,
273
- components : getSliceZoneComponents ( {
273
+ components : defineSliceZoneComponents ( {
274
274
foo : Foo ,
275
275
bar : Bar ,
276
276
} ) ,
@@ -300,7 +300,7 @@ test("wraps output with provided wrapper component", (t) => {
300
300
const wrapper = mount ( SliceZoneImpl , {
301
301
props : {
302
302
slices : [ { slice_type : "foo" } , { slice_type : "bar" } ] ,
303
- components : getSliceZoneComponents ( {
303
+ components : defineSliceZoneComponents ( {
304
304
foo : Foo ,
305
305
bar : Bar ,
306
306
} ) ,
@@ -323,7 +323,7 @@ test("renders nothing when invalid", (t) => {
323
323
const wrapper = mount ( SliceZoneImpl , {
324
324
props : {
325
325
slices : null as unknown as SliceZoneLike < SliceLike > ,
326
- components : getSliceZoneComponents ( { } ) ,
326
+ components : defineSliceZoneComponents ( { } ) ,
327
327
} ,
328
328
} ) ;
329
329
@@ -352,7 +352,7 @@ test("reacts to changes properly", async (t) => {
352
352
const wrapper = mount ( SliceZoneImpl , {
353
353
props : {
354
354
slices : [ { slice_type : "foo" } , { slice_type : "bar" } ] ,
355
- components : getSliceZoneComponents ( {
355
+ components : defineSliceZoneComponents ( {
356
356
foo : Foo ,
357
357
bar : Bar ,
358
358
} ) ,
@@ -363,7 +363,7 @@ test("reacts to changes properly", async (t) => {
363
363
364
364
await wrapper . setProps ( {
365
365
slices : [ { slice_type : "bar" } ] ,
366
- components : getSliceZoneComponents ( {
366
+ components : defineSliceZoneComponents ( {
367
367
foo : Foo ,
368
368
bar : Bar ,
369
369
} ) ,
0 commit comments