Preserve custom Street Level provider switches in shared state

This commit is contained in:
Sameh Khamis committed 2026-10-09 17:53:47 -07:00
1 parent 3b840ebdf3
commit 7b1b2df764
11 files changed
+238 -9

No files matched your search

+11
View File
@@ -98,6 +98,17 @@ function withPublishedBase(
}
function writeCodecFixture(cwd, rows, entries) {
const providerCodec = path.join(
cwd,
'src/layers/streetLevel/providerSwitches.js',
);
mkdirSync(path.dirname(providerCodec), { recursive: true });
writeFileSync(
providerCodec,
readFileSync(
new URL('../layers/streetLevel/providerSwitches.js', import.meta.url),
),
);
const source = readFileSync(CODEC_SOURCE_PATH, 'utf8');
const registryEnd = ']);\n\nexport const REGISTERED_LAYER_IDS';
assert.equal(source.split(registryEnd).length, 2);