test: update test implementation to work well with typescript 6#1436
test: update test implementation to work well with typescript 6#1436joker23 wants to merge 1 commit into
Conversation
|
@launchdarkly/js-sdk-common size report |
|
@launchdarkly/js-client-sdk size report |
|
@launchdarkly/browser size report |
0f187c2 to
73ce3d2
Compare
|
@launchdarkly/js-client-sdk-common size report |
|
@cursor review |
There was a problem hiding this comment.
✅ Bugbot reviewed your changes and found no new issues!
Comment @cursor review or bugbot run to trigger another review on this PR
Reviewed by Cursor Bugbot for commit 73ce3d2. Configure here.
73ce3d2 to
d2160b2
Compare
d2160b2 to
5010b22
Compare
This PR will update the way that tests import modules. This is to make the syntax of this module compatible with typescript 6.
Specifically the issue that the current syntax runs into is detailed in https://devblogs.microsoft.com/typescript/announcing-typescript-6-0/#deprecated:---esmoduleinterop-false-and---allowsyntheticdefaultimports-false
Note
Low Risk
Test and compiler-option changes only; no production runtime or public API changes.
Overview
Prepares the monorepo for TypeScript 6 by turning on
esModuleInterop: trueintsconfig.jsonfor edge SDK packages (akamai-base,akamai-edgekv,cloudflare,fastly,shopify-oxygen,vercel), shared packages (akamai-edgeworker-sdk,sdk-client,sdk-server-edge), and related configs.Tests that load fixture JSON are updated from namespace imports (
import * as testData from '...json') to default imports (import testData from '...json'), matching howresolveJsonModulebehaves with interop enabled. The same pattern is applied across edge integration tests and manysdk-clientLDClientImpltests that usemockResponse.json.packages/sdk/fastly/jest.config.jsonis reformatted only (no behavior change).Reviewed by Cursor Bugbot for commit 5010b22. Bugbot is set up for automated code reviews on this repo. Configure here.