Skip to content

test(web): 为 bootstrapSession 增加显式测试 reset hook #76

Description

@ghbvf

Source

From PR #65 review follow-up: #65 (comment)

Context

Cx3 legacy item: bootstrapSession currently has no _resetBootstrapForTesting hook. Tests rely on vi.resetModules(), which works today, so PR #65 intentionally did not add a YAGNI export.

Desired direction

Add an explicit test-only reset hook only if bootstrap tests become brittle, slow, or need to coordinate multiple bootstrap cycles in one module instance. Keep it out of production app assembly semantics.

Acceptance

  • Bootstrap tests can reset bootstrap singleton state without relying on module cache resets.
  • The hook is clearly test-only and does not become part of public runtime API.
  • Existing cold-start refresh behavior remains covered.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    frontend前端 gocell-webpkg/webapps/web 装配层priority/p3低优先级 / backlog

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions