Skip to content

test(ts-plugin): move named exports tests into per-feature test files#359

Merged
mizdra merged 2 commits intomainfrom
refactor-test-for-named-export
Apr 12, 2026
Merged

test(ts-plugin): move named exports tests into per-feature test files#359
mizdra merged 2 commits intomainfrom
refactor-test-for-named-export

Conversation

@mizdra
Copy link
Copy Markdown
Owner

@mizdra mizdra commented Apr 12, 2026

Summary

  • Removed named-exports.test.ts which had limited coverage for named exports scenarios
  • Moved named exports test cases into the corresponding per-feature test files: code-fix.test.ts, completion.test.ts, find-all-references.test.ts, and go-to-definition.test.ts
  • Added test cases that cover behaviors and code paths that differ between named exports (import * as styles) and default exports (import styles) modes
  • Only features with diverging behavior between the two export modes received new named exports test cases; features sharing the same code path or already covered by other tests were left unchanged

Motivation

The previous approach of grouping all named exports tests in a single file made it harder to understand what behaviors were covered per feature, and left many named-exports-specific behaviors untested. By co-locating named exports tests with their feature counterparts, coverage is improved and test intent becomes clearer.

Test plan

  • Run vp test --project e2e and confirm all tests pass
  • Verify deleted named-exports.test.ts scenarios are covered by the updated per-feature test files

🤖 Generated with Claude Code

mizdra and others added 2 commits April 12, 2026 21:18
Previously, named exports tests were consolidated in a single file
(named-exports.test.ts) with only limited coverage. This commit moves
those tests into the corresponding per-feature test files
(code-fix, completion, find-all-references, go-to-definition) and adds
test cases for behaviors that differ between named exports and default
exports.

Note: not all feature test files received named exports test cases —
only features with code paths or behaviors that differ between the two
export modes were updated. Features that share the same code path or
are already sufficiently covered by other tests were left unchanged.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@changeset-bot
Copy link
Copy Markdown

changeset-bot bot commented Apr 12, 2026

⚠️ No Changeset found

Latest commit: 34bebe2

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@mizdra mizdra added Type: Refactoring A code change that neither fixes a bug nor adds a feature Type: Testing Adding missing tests or correcting existing tests and removed Type: Refactoring A code change that neither fixes a bug nor adds a feature labels Apr 12, 2026
@mizdra mizdra merged commit 87c2473 into main Apr 12, 2026
20 checks passed
@mizdra mizdra deleted the refactor-test-for-named-export branch April 12, 2026 15:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Type: Testing Adding missing tests or correcting existing tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant