-
-
Notifications
You must be signed in to change notification settings - Fork 256
feat: add override functionality to remote feature flags #7271
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from 1 commit
bec04d7
e78270a
fe7db8b
4413b2d
e07e67c
ec17188
fbdbd14
c9cd5aa
4d02e47
e3a4f8f
35b8470
4201e40
7ae47a3
71e4b7a
ca479c8
0063bce
9bbf745
414f0f0
f17c947
4d349ed
6a6b98f
7e3500d
434c892
6c75509
e562809
a09ceaa
ffd58e9
c1af969
9d99264
1f49998
e8f2ff1
83017de
6447545
28a8548
c3d09e5
10c168d
d1357b7
fb818a8
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
- Loading branch information
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -130,6 +130,8 @@ describe('Bridge Quotes Utils', () => { | |||||||||||||||||||||||||||||
| remoteFeatureFlags: { | ||||||||||||||||||||||||||||||
| confirmations_pay: getFeatureFlagsMock(), | ||||||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||||||
| abTestRawFlags: {}, | ||||||||||||||||||||||||||||||
| localOverrides: {}, | ||||||||||||||||||||||||||||||
| })); | ||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||
| getFeatureFlagsMock.mockReturnValue(FEATURE_FLAGS_MOCK); | ||||||||||||||||||||||||||||||
|
|
@@ -1019,6 +1021,8 @@ describe('Bridge Quotes Utils', () => { | |||||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||||||
| abTestRawFlags: {}, | ||||||||||||||||||||||||||||||
| localOverrides: {}, | ||||||||||||||||||||||||||||||
| }); | ||||||||||||||||||||||||||||||
|
Comment on lines
1013
to
1026
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Similar as above, it would be better to spread the result of
Suggested change
|
||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||
| const result = getBridgeRefreshInterval({ | ||||||||||||||||||||||||||||||
|
|
@@ -1042,6 +1046,8 @@ describe('Bridge Quotes Utils', () => { | |||||||||||||||||||||||||||||
| refreshRate: 456000, | ||||||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||||||
| abTestRawFlags: {}, | ||||||||||||||||||||||||||||||
| localOverrides: {}, | ||||||||||||||||||||||||||||||
| }); | ||||||||||||||||||||||||||||||
|
Comment on lines
1037
to
1051
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Similar as above, it would be better to spread the result of
Suggested change
|
||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||
| const result = getBridgeRefreshInterval({ | ||||||||||||||||||||||||||||||
|
|
@@ -1064,6 +1070,8 @@ describe('Bridge Quotes Utils', () => { | |||||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||||||
| abTestRawFlags: {}, | ||||||||||||||||||||||||||||||
| localOverrides: {}, | ||||||||||||||||||||||||||||||
| }); | ||||||||||||||||||||||||||||||
|
Comment on lines
1062
to
1075
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||
| const result = getBridgeRefreshInterval({ | ||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -178,6 +178,8 @@ describe('Relay Quotes Utils', () => { | |
| getRemoteFeatureFlagControllerStateMock.mockReturnValue({ | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I won't add suggestions for these tests, but the same thing applies as above. |
||
| cacheTimestamp: 0, | ||
| remoteFeatureFlags: {}, | ||
| abTestRawFlags: {}, | ||
| localOverrides: {}, | ||
| }); | ||
|
|
||
| getDelegationTransactionMock.mockResolvedValue(DELEGATION_RESULT_MOCK); | ||
|
|
@@ -553,6 +555,8 @@ describe('Relay Quotes Utils', () => { | |
| relayQuoteUrl, | ||
| }, | ||
| }, | ||
| abTestRawFlags: {}, | ||
| localOverrides: {}, | ||
| }); | ||
|
|
||
| await getRelayQuotes({ | ||
|
|
@@ -913,6 +917,8 @@ describe('Relay Quotes Utils', () => { | |
| relayDisabledGasStationChains: [QUOTE_REQUEST_MOCK.sourceChainId], | ||
| }, | ||
| }, | ||
| abTestRawFlags: {}, | ||
| localOverrides: {}, | ||
| }); | ||
|
|
||
| const result = await getRelayQuotes({ | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -23,6 +23,8 @@ describe('Feature Flags Utils', () => { | |
| getRemoteFeatureFlagControllerStateMock.mockReturnValue({ | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The same thing applies as above. |
||
| cacheTimestamp: 0, | ||
| remoteFeatureFlags: {}, | ||
| abTestRawFlags: {}, | ||
| localOverrides: {}, | ||
| }); | ||
| }); | ||
|
|
||
|
|
@@ -56,6 +58,8 @@ describe('Feature Flags Utils', () => { | |
| slippage: SLIPPAGE_MOCK, | ||
| }, | ||
| }, | ||
| abTestRawFlags: {}, | ||
| localOverrides: {}, | ||
| }); | ||
|
|
||
| const featureFlags = getFeatureFlags(messenger); | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Similar as above, it would be better to spread the result of
getDefaultRemoteFeatureFlagControllerState()first: