From cd8d6273b41608f6433aad16124c8ea041dcb954 Mon Sep 17 00:00:00 2001 From: Thomas Heartman Date: Wed, 8 Nov 2023 14:25:26 +0100 Subject: [PATCH 1/2] chore: add detect segment usage in CRs --- src/lib/types/experimental.ts | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/lib/types/experimental.ts b/src/lib/types/experimental.ts index 690d584c5a19..5832ff7f64e6 100644 --- a/src/lib/types/experimental.ts +++ b/src/lib/types/experimental.ts @@ -36,7 +36,8 @@ export type IFlagKey = | 'featureSwitchRefactor' | 'featureSearchAPI' | 'featureSearchFrontend' - | 'scheduledConfigurationChanges'; + | 'scheduledConfigurationChanges' + | 'detectSegmentUsageInChangeRequests'; export type IFlags = Partial<{ [key in IFlagKey]: boolean | Variant }>; @@ -172,6 +173,11 @@ const flags: IFlags = { process.env.UNLEASH_EXPERIMENTAL_SCHEDULED_CONFIGURATION_CHANGES, false, ), + detectSegmentUsageInChangeRequests: parseEnvVarBoolean( + process.env + .UNLEASH_EXPERIMENTAL_DETECT_SEGMENT_USAGE_IN_CHANGE_REQUESTS, + false, + ), }; export const defaultExperimentalOptions: IExperimentalOptions = { From c43c3743b5a6ab5446756ba4a171ce4e11442720 Mon Sep 17 00:00:00 2001 From: Thomas Heartman Date: Wed, 8 Nov 2023 14:36:28 +0100 Subject: [PATCH 2/2] chore: update snapshot --- src/lib/__snapshots__/create-config.test.ts.snap | 1 + 1 file changed, 1 insertion(+) diff --git a/src/lib/__snapshots__/create-config.test.ts.snap b/src/lib/__snapshots__/create-config.test.ts.snap index 90f9fe4ea22d..5c07d1b07efe 100644 --- a/src/lib/__snapshots__/create-config.test.ts.snap +++ b/src/lib/__snapshots__/create-config.test.ts.snap @@ -77,6 +77,7 @@ exports[`should create default config 1`] = ` "customRootRolesKillSwitch": false, "demo": false, "dependentFeatures": false, + "detectSegmentUsageInChangeRequests": false, "disableBulkToggle": false, "disableEnvsOnRevive": false, "disableMetrics": false,