1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-11-21 17:37:01 +01:00
metamask-extension/test
Elliot Winkler 7e97ff2be4
Expand network controller unit test coverage (#17498)
The network controller has some tests, but they are incomplete and don't
follow our latest best practices for writing unit tests.

This commit greatly increases the amount of test coverage for the API
that we want to retain in NetworkController, in particular the seemingly
myriad paths that the code takes starting from `initializeProvider`,
`resetConnection`, `setRpcTarget`, `setProviderType`,
`rollbackToPreviousProvider`, and `lookupNetwork`.

There were a couple of pieces of logic I noted which don't seem to have
any effect due to being redundant or unreachable, but they also don't
make our lives more difficult, either, so I opted to leave them in.

Co-authored-by: Mark Stacey <markjstacey@gmail.com>
Co-authored-by: Zachary Belford <belfordz66@gmail.com>
2023-02-08 13:10:04 -07:00
..
data Refactor ConfirmTransaction to Functional Component (#17473) 2023-02-08 18:00:25 +07:00
e2e converted collectibles files to nfts (#17658) 2023-02-08 20:04:56 +05:30
helpers Activate LavaMoat scuttling security feature (#17276) 2023-01-24 19:00:35 +02:00
jest Expand network controller unit test coverage (#17498) 2023-02-08 13:10:04 -07:00
lib Use async/await instead of Promise.resolve (#16221) 2023-01-20 14:20:18 -06:00
mocks remove exclusions for mismatched object jsdoc type casing (#15351) 2022-07-27 08:28:05 -05:00
stub Convert Transaction constants to typescript (#17149) 2023-01-18 08:47:29 -06:00
unit-global Add lockdown e2e test (#12562) 2021-11-02 17:01:01 -07:00
env.js Adding static icon names to test env file (#16078) 2022-11-18 22:28:38 +05:30
merge-coverage.js decrease coverage threshold that requires bump (#17544) 2023-02-02 16:43:55 -06:00
run-unit-tests.js split unit tests (#16455) 2023-01-11 12:23:38 -06:00
setup.js Add initial Typescript Files (#15596) 2022-08-16 10:15:29 -05:00