We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f3f0cee commit 0e0d340Copy full SHA for 0e0d340
src/lib/Actions.test.ts
@@ -74,15 +74,18 @@ describe(
74
const baseItem = {
75
field: 'value'
76
};
77
- const callback = (item?: object | undefined): boolean => {
+ const callback = (item?: unknown): void => {
78
called = true;
79
// @ts-ignore
80
item.field = 'newValue';
81
- return called;
82
83
const action = new CallbackAction('', null, callback);
84
85
- expect(action.call(baseItem)).toBe(true);
+ expect(called).toBe(false);
+
86
+ action.call(baseItem)
87
88
+ expect(called).toBe(true);
89
expect(baseItem.field).toBe('newValue');
90
});
91
},
0 commit comments