repo.or.cz
/
ProtonMail-WebClient.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
Merge branch 'renovate/all-minor-patch' into 'main'
[ProtonMail-WebClient.git]
/
packages
/
testing
/
lib
/
mockUseFlag.ts
blob
ec7a7657b6f3eac748e60844e2075878694b8ac6
1
import * as useFlagModule from '@proton/unleash';
2
3
export const mockUseFlag = (value: boolean = false) => {
4
const mockedUseFlag = jest.spyOn(useFlagModule, 'useFlag');
5
6
mockedUseFlag.mockReturnValue(value);
7
8
return mockedUseFlag;
9
};