Commit 3257f3a
authored
refactor: use shallow to fix react warning (#1236)
Switcher test (`src\tests\unit\tests\DetailsView\components\switcher.test.tsx`) is showing warnings (while running the unit tests): **componentWillRecieveProps has been renamed...**
The warning mention to update `DropdownBase` which is on the office fabric side (one more reason to update our office ui fabric version) but we can fix this warning by not `mount`ing the tested component. Instead, we can use `shallow` which will not call to the base component.1 parent afb1cfc commit 3257f3a
File tree
1 file changed
+2
-2
lines changed- src/tests/unit/tests/DetailsView/components
1 file changed
+2
-2
lines changedLines changed: 2 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | | - | |
| 3 | + | |
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
| |||
40 | 40 | | |
41 | 41 | | |
42 | 42 | | |
43 | | - | |
| 43 | + | |
44 | 44 | | |
45 | 45 | | |
46 | 46 | | |
| |||
0 commit comments