-
Notifications
You must be signed in to change notification settings - Fork 34
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
test: changes to jest tests to remove console warnings (#1499)
Changes in this PR are are refactoring and jest test improvements: Refactor: * replace windowHeight redux prop with the WindowDimensions context (all components needing window width/height now use the context) Testing: * EditBar.spec: use async/act to trigger useEffect and mocked api request - removes error about api request (tests still passed but there was a console error) * EditDashboard.spec: mock the EditBar and focus on EditDashboard functionality * Dashboard: use testing-library and test the default component export, which results in mapStateToProps also getting covered by the tests * Named functions for mocks - removes warning
- Loading branch information
1 parent
8f108a7
commit c9ed0f6
Showing
17 changed files
with
515 additions
and
807 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.