Skip to content

Add tests for tidier.js#3887

Open
Geethegreat wants to merge 1 commit intoprocessing:develop-codemirror-v6from
Geethegreat:tidy-prettier-tests
Open

Add tests for tidier.js#3887
Geethegreat wants to merge 1 commit intoprocessing:develop-codemirror-v6from
Geethegreat:tidy-prettier-tests

Conversation

@Geethegreat
Copy link

Fixes #3816

Changes:
Adds Jest test coverage for tidier.js to verify:

  • Running “Tidy Code” updates the editor document using prettier.formatWithCursor
  • The cursor position is preserved and updated correctly
  • Formatting works for JavaScript, CSS, and HTML modes
  • Unsupported modes do not trigger formatting
    Prettier is mocked to ensure the tests validate our integration behavior rather than Prettier internals.

I have verified that this pull request:

  • has no linting errors (npm run lint)
  • has no test errors (npm run test)
  • has no typecheck errors (npm run typecheck)
  • is from a uniquely-named feature branch and is up to date with the develop branch.
  • is descriptively named and links to an issue number, i.e. Fixes #123
  • meets the standards outlined in the accessibility guidelines

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