Skip to content

Chore/sibujs quality followups#39

Merged
hexplus merged 42 commits into
mainfrom
chore/sibujs-quality-followups
Jun 26, 2026
Merged

Chore/sibujs quality followups#39
hexplus merged 42 commits into
mainfrom
chore/sibujs-quality-followups

Conversation

@hexplus

@hexplus hexplus commented Jun 26, 2026

Copy link
Copy Markdown
Owner

Description

Restores the test coverage that the duplicate-instance hardening shims reduced — pure test/coverage work, no behavior change.

The globalThis first-copy-wins registries added for duplicate-runtime resilience have a "a duplicate copy loaded" branch that the normal suite can't reach (the source module evaluates exactly once, always taking the first-copy path), which left track.ts at 33% branch and batch.ts at 90%.

  • Adds tests/duplicate-instance-source.test.ts — covers the duplicate-detection path on the real source modules by pre-seeding the globalThis registry as if a first copy had published its API, then freshly importing the module so its resolver executes the duplicate branch (delegates to the first copy, dev-warns once, batch re-exports the first copy's functions).
  • Adds a justified /* v8 ignore */ on the __SIBU_VERSION__ build-define branch in track.ts (only inlined by the bundler, never reachable in source tests — matches the existing __SIBU_DEV__ pattern in dev.ts).

Result: track.ts and batch.ts are back to 100% across all metrics. Full suite: 321 files / 3954 tests pass.

Related Issue

Closes #

Type of Change

  • Bug fix
  • New feature
  • Breaking change
  • Documentation update

(Test coverage / chore — none of the above categories apply; no production behavior change.)

Checklist

  • I have read CONTRIBUTING.md
  • My code builds without errors
  • I have tested my changes
  • I have updated documentation if needed

hexplus added 30 commits March 28, 2026 15:11
@hexplus hexplus merged commit 3397e56 into main Jun 26, 2026
1 check passed
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