refactor: Unify Karma tsconfigs #3296
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This pull request updates TypeScript configuration files related to testing, mainly by centralizing the configuration of type definitions for Karma tests. The main change is moving the specification of test-related type definitions from individual package-level
tsconfig.karma.jsonfiles into the roottsconfig.karma.json, simplifying and unifying the configuration across packages.Changes
Centralization and simplification of test type definitions:
tsconfig.karma.jsonnow includes all necessary test-related type definitions (jest,jest-extended, and@streamr/test-utils/customMatcherTypes) in itstypesarray, ensuring consistent type support for tests across all packages.displayfield in the roottsconfig.karma.jsonwas updated to use a hyphen instead of an en dash for consistency.Cleanup of package-level configurations:
typesarrays from thetsconfig.karma.jsonfiles inpackages/dht,packages/proto-rpc,packages/trackerless-network, andpackages/utils, as these are now inherited from the root config. [1] [2] [3]Other minor updates:
tsconfig.karma.jsonnow only includes the latest ECMAScript and DOM libraries in itslibarray, removing older versions for clarity and modernity1.Footnotes
libfield is cumulative – includingESNext(bleeding edge) means we implicitly include all previous. ↩