Skip to content

Migrate bench/test for area, bbox-clip, bezier-spline, and buffer#3059

Draft
mfedderly wants to merge 3 commits intomasterfrom
mf/migrate-test-bench-1
Draft

Migrate bench/test for area, bbox-clip, bezier-spline, and buffer#3059
mfedderly wants to merge 3 commits intomasterfrom
mf/migrate-test-bench-1

Conversation

@mfedderly
Copy link
Copy Markdown
Collaborator

@mfedderly mfedderly commented May 2, 2026

Continues the path set forth in #3038 for a few more packages.

  • testFixtures is extended to handle non-geojson return values as well
  • Migrate some root package.json dependencies to the pnpm catalog version
  • Limited the node --test execution to test.ts only, which avoid conflicts in packages with tstyche type testing

Side notes that I discovered while working on this:

  • colorize gets implemented in many different test.ts files. Consolidating this is out of scope for this push because they're slightly different
  • TypeScript 6 is going to have us change how we're referencing index.ts in each of these test/bench files
  • TypeScript 6 is also going to force us to be explicit about when we're including @types/node
  • In order to support the boolean packages, we need to handle true and false test subdirectories. Perhaps this is just a different test runner

Depends on #3061

Comment thread support/testFixtures.mts
!VALID_TYPES.has(result.type)
) {
outputPath = outputPath.replace(/\.geojson$/, ".json");
}
Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

area() actually just returns a number, so it makes sense to have test/out/*.json and not .geojson.

@mfedderly
Copy link
Copy Markdown
Collaborator Author

The build is failing here because node@18 doesn't support working against TypeScript files directly.

@mfedderly mfedderly marked this pull request as draft May 2, 2026 18:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant