Skip to content

Commit b9dac86

Browse files
committed
fix test case for vault not updated
1 parent 331c799 commit b9dac86

File tree

2 files changed

+3
-30
lines changed

2 files changed

+3
-30
lines changed

packages/keyring-controller/jest.config.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,10 +17,10 @@ module.exports = merge(baseConfig, {
1717
// An object that configures minimum threshold enforcement for coverage results
1818
coverageThreshold: {
1919
global: {
20-
branches: 93.1,
20+
branches: 94.25,
2121
functions: 100,
22-
lines: 98.64,
23-
statements: 98.65,
22+
lines: 98.79,
23+
statements: 98.8,
2424
},
2525
},
2626

packages/keyring-controller/src/KeyringController.test.ts

Lines changed: 0 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -3066,33 +3066,6 @@ describe('KeyringController', () => {
30663066
);
30673067
});
30683068

3069-
!cacheEncryptionKey &&
3070-
it('should not upgrade the vault encryption if the generic encryptor has the same parameters', async () => {
3071-
await withController(
3072-
{
3073-
skipVaultCreation: true,
3074-
cacheEncryptionKey,
3075-
state: { vault: 'my vault' },
3076-
},
3077-
async ({ controller, encryptor }) => {
3078-
jest.spyOn(encryptor, 'isVaultUpdated').mockReturnValue(true);
3079-
const encryptSpy = jest.spyOn(encryptor, 'encrypt');
3080-
jest.spyOn(encryptor, 'decrypt').mockResolvedValueOnce([
3081-
{
3082-
type: KeyringTypes.hd,
3083-
data: {
3084-
accounts: ['0x123'],
3085-
},
3086-
},
3087-
]);
3088-
3089-
await controller.submitPassword(password);
3090-
3091-
expect(encryptSpy).toHaveBeenCalledTimes(1);
3092-
},
3093-
);
3094-
});
3095-
30963069
!cacheEncryptionKey &&
30973070
it('should throw error if password is of wrong type', async () => {
30983071
await withController(

0 commit comments

Comments
 (0)