Skip to content

chore: migrate test-suite to ESLint config v3 - #2465

Merged
kpal81xd merged 4 commits into
mainfrom
chore/eslint-config-v3-test-suite
Oct 29, 2026
Merged

kpal81xd merged 4 commits into
mainfrom
chore/eslint-config-v3-test-suite

Conversation

@kpal81xd

@kpal81xd kpal81xd commented Oct 29, 2026 •

Copy link
Copy Markdown
Contributor

Part of playcanvas/eslint-config#48.

What's Changed

  • Bump the test-suite/ package's @playcanvas/eslint-config from 2.1.0 to 3.0.0-beta.9 and use its /typescript entry point, matching the root package.
  • Remove the hand-wired @typescript-eslint/parser setup and the @typescript-eslint/parser and globals devDependencies, which are no longer used.
  • Remove overrides the shared config covers or that no longer apply: the jsdoc/*, no-use-before-define, no-await-in-loop and no-loop-func offs, import/no-unresolved off for .mjs, the import/resolver settings, and the globals blocks. That includes config / editor, which only appeared in .ts files, where no-undef is off and globals.d.ts types them. The only override left is the existing ignore for the vendored ammo fixture.
  • Apply the autofixable import rules (import-x/order, top-level import type).
  • Replace all 161 explicit anys with real types instead of turning no-explicit-any off:
    • engine objects use playcanvas types (AppBase, Entity, AssetResource<...>), with ! / casts where the tests rely on a component or lookup being present;
    • the monaco editor uses monaco-editor, the realtime connection sharedb, observers and event handles @playcanvas/observer, and assets and entities the editor-api types;
    • only shapes with no published type stay hand-written in globals.d.ts: messenger and REST payloads (the REST client returns unknown), editor-internal objects such as the layout.assets panel, and the props tests stamp on window.
  • Add playcanvas 2.23.3, monaco-editor 0.47.0 and @types/sharedb 3.3.13 as exact-pinned devDependencies, matching the root package, for types only.
  • Raise engines.node to ^22.13.0 || >=24 to match the new config's requirement. test-suite-ci.yml already runs Node 26.
  • No runtime change: every changed .ts file compiles to the same JavaScript as on main, so the edits are type-only.

Checks

Manual smoke test

  1. Open test-suite/lib/pages/assets.ts in an editor with the ESLint extension, from a test-suite/ install.
    Expected: no ESLint problems.
  2. In the same file, add const x: any = 1;.
    Expected: ESLint flags @typescript-eslint/no-explicit-any as an error.
  3. Hover asset in a callback such as (asset: Asset) => asset.get('name').
    Expected: the editor shows the editor-api Asset type, not any.

@kpal81xd kpal81xd added enhancement New feature or request release: next patch Ticket marked for next patch release dependencies Pull requests that update a dependency file labels Oct 29, 2026
@kpal81xd kpal81xd self-assigned this Oct 29, 2026
@vercel

vercel Bot commented Oct 29, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
editor Ready Ready Preview Oct 29, 2026 4:23pm UTC

Request Review

@kpal81xd
kpal81xd merged commit 5c4f7d8 into main Oct 29, 2026
9 checks passed
@kpal81xd
kpal81xd deleted the chore/eslint-config-v3-test-suite branch October 29, 2026 16:25

This branch was successfully deployed

1 active deployment
Preview — d40fe561 Deployed Oct 29, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file enhancement New feature or request release: next patch Ticket marked for next patch release

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant