mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-11-29 07:16:36 +01:00
35ac762e10
This PR adds `snaps` under Flask build flags to the extension. This branch is mostly equivalent to the current production version of Flask, excepting some bug fixes and tweaks. Closes #11626
23 lines
732 B
JavaScript
23 lines
732 B
JavaScript
import { endowmentPermissionBuilders } from '@metamask/snap-controllers';
|
|
import { restrictedMethodPermissionBuilders } from '@metamask/rpc-methods';
|
|
import { EndowmentPermissions, RestrictedMethods } from './permissions';
|
|
|
|
describe('EndowmentPermissions', () => {
|
|
it('has the expected permission keys', () => {
|
|
expect(Object.keys(EndowmentPermissions).sort()).toStrictEqual(
|
|
Object.keys(endowmentPermissionBuilders).sort(),
|
|
);
|
|
});
|
|
});
|
|
|
|
describe('RestrictedMethods', () => {
|
|
it('has the expected permission keys', () => {
|
|
expect(Object.keys(RestrictedMethods).sort()).toStrictEqual(
|
|
[
|
|
'eth_accounts',
|
|
...Object.keys(restrictedMethodPermissionBuilders),
|
|
].sort(),
|
|
);
|
|
});
|
|
});
|