diff --git a/modules/FeatureFlags/src/SimpleModule.FeatureFlags.Contracts/FeatureFlagsFeatures.cs b/modules/FeatureFlags/src/SimpleModule.FeatureFlags.Contracts/FeatureFlagsFeatures.cs new file mode 100644 index 00000000..58fa5a10 --- /dev/null +++ b/modules/FeatureFlags/src/SimpleModule.FeatureFlags.Contracts/FeatureFlagsFeatures.cs @@ -0,0 +1,8 @@ +using SimpleModule.Core.FeatureFlags; + +namespace SimpleModule.FeatureFlags.Contracts; + +public sealed class FeatureFlagsFeatures : IModuleFeatures +{ + public const string OverrideManagement = "FeatureFlags.OverrideManagement"; +} diff --git a/modules/FeatureFlags/src/SimpleModule.FeatureFlags/types.ts b/modules/FeatureFlags/src/SimpleModule.FeatureFlags/types.ts index 09cf293d..623ca0a7 100644 --- a/modules/FeatureFlags/src/SimpleModule.FeatureFlags/types.ts +++ b/modules/FeatureFlags/src/SimpleModule.FeatureFlags/types.ts @@ -16,6 +16,9 @@ export interface FeatureFlagOverride { isEnabled: boolean; } +export interface FeatureFlagsFeatures { +} + export interface SetOverrideRequest { overrideType: any; overrideValue: string; diff --git a/playwright.config.ts b/playwright.config.ts index dc1a825c..7af63794 100644 --- a/playwright.config.ts +++ b/playwright.config.ts @@ -4,6 +4,9 @@ import { defineConfig, devices } from '@playwright/test'; * Root-level config that delegates to tests/e2e. * Allows `npx playwright test` from repo root to work correctly. */ + +const baseURL = process.env.PLAYWRIGHT_BASE_URL ?? 'https://localhost:5001'; + export default defineConfig({ testDir: './tests/e2e/tests', fullyParallel: true, @@ -12,7 +15,7 @@ export default defineConfig({ workers: process.env.CI ? 1 : undefined, reporter: [['html', {}], ...(process.env.CI ? [['github', {}] as const] : [])], use: { - baseURL: 'https://localhost:5001', + baseURL, trace: 'on-first-retry', ignoreHTTPSErrors: true, screenshot: 'only-on-failure', @@ -44,13 +47,13 @@ export default defineConfig({ ], webServer: { command: 'dotnet run --project template/SimpleModule.Host', - url: 'https://localhost:5001/health/live', + url: `${baseURL}/health/live`, reuseExistingServer: true, ignoreHTTPSErrors: true, timeout: 60_000, env: { ...process.env, - ASPNETCORE_URLS: 'https://localhost:5001', + ASPNETCORE_URLS: baseURL, Database__DefaultConnection: 'Data Source=e2e-test.db', }, }, diff --git a/tests/e2e/playwright.config.ts b/tests/e2e/playwright.config.ts index f7e7d9db..5590aede 100644 --- a/tests/e2e/playwright.config.ts +++ b/tests/e2e/playwright.config.ts @@ -1,7 +1,8 @@ import { defineConfig, devices } from '@playwright/test'; const isCI = !!process.env.CI; -const baseURL = isCI ? 'http://localhost:5000' : 'https://localhost:5001'; +const baseURL = + process.env.PLAYWRIGHT_BASE_URL ?? (isCI ? 'http://localhost:5000' : 'https://localhost:5001'); export default defineConfig({ testDir: './tests',