fix(config): keep public/config.json equal to the local profile (F-5, 13-15)
public/config.json is the copy dev serves and nothing compared it with config/runtime/local.json. A unit test now requires it to equal what a local build writes, and sample removal drops the feature override from it too. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 5.5
parent
4d17259037
commit
edf44a2253
@@ -244,18 +244,16 @@ try {
|
||||
|
||||
// Runtime profiles are product configuration. Once the feature is physically
|
||||
// removed, its override key must disappear too or the built config still
|
||||
// advertises a source capability that no longer exists.
|
||||
for (const profile of [
|
||||
"local",
|
||||
"development",
|
||||
"staging",
|
||||
"production",
|
||||
] as const) {
|
||||
const profilePath = path.join(
|
||||
fixtureRoot,
|
||||
"config/runtime",
|
||||
`${profile}.json`,
|
||||
);
|
||||
// advertises a source capability that no longer exists. public/config.json
|
||||
// is the local profile `dev` serves and has to stay equal to it (F-5).
|
||||
for (const configPath of [
|
||||
"config/runtime/local.json",
|
||||
"config/runtime/development.json",
|
||||
"config/runtime/staging.json",
|
||||
"config/runtime/production.json",
|
||||
"public/config.json",
|
||||
]) {
|
||||
const profilePath = path.join(fixtureRoot, configPath);
|
||||
const runtimeConfig = JSON.parse(
|
||||
await readFile(profilePath, "utf8"),
|
||||
) as {
|
||||
|
||||
Reference in New Issue
Block a user