Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 07f7c83

Browse files
committed
do not need to turn the active flag to true for test
1 parent 8d85085 commit 07f7c83

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

libs/core/testing/src/lib/test-bed.ts

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ import { ComponentFixture, TestBed } from '@angular/core/testing';
33
import {
44
getLocalState,
55
injectCanvasRootInitializer,
6-
injectStore,
76
NGT_STORE,
87
NgtAnyRecord,
98
NgtCanvasOptions,
@@ -42,7 +41,6 @@ export class NgtTestBed {
4241
provide: ENVIRONMENT_INITIALIZER,
4342
useFactory: () => {
4443
const initRoot = injectCanvasRootInitializer();
45-
const store = injectStore();
4644

4745
return () => {
4846
const configurator = initRoot(mockedCanvas);
@@ -57,8 +55,6 @@ export class NgtTestBed {
5755
...canvasConfiguration,
5856
events: undefined,
5957
});
60-
61-
store.update((state) => ({ internal: { ...state.internal, active: true } }));
6258
};
6359
},
6460
multi: true,
@@ -145,7 +141,9 @@ export class NgtTestBed {
145141
target: el,
146142
currentTarget: el,
147143
sourceEvent: eventData,
144+
nativeEvent: eventData,
148145
object: el,
146+
eventObject: el,
149147
...eventData,
150148
};
151149

0 commit comments

Comments
 (0)