Skip to content

Re-enable frontend suites skipped by the batch-connectivity → SSE-reachability migration #175

Description

@jgruberf5

Split from #39 (frontend debt umbrella). This is the "re-enable skipped suites" item, scoped and root-caused.

The 10 skipped tests

  • K8sClusterList.test.tsx — 3 (shows Active status badge, shows Unreachable status badge, uses connected status as primary truth)
  • Fleet.test.tsx — 3 (prioritizes connected access status, keeps connected primary truth, shows diagnostic probe status secondarily)
  • k8s-explorer.integration.test.tsx — 4 (loading skeleton, empty state, disables generic ingress creation on OpenShift, mutation-boundary notice)

Root cause (verified empirically)

The K8sClusterList / Fleet reachability skips are not "just needs an MSW mock" as their inline TODOs say. The reachability display migrated: ClusterStatusBadge (ui/ClusterStatusBadge.tsx) now reads from the SSE-driven reachability registry via useTargetConnectivity(targetType, targetId) — the cluster probe for direct/operator clusters, the SSH probe for jumphost clusters. It no longer consumes the batch GET /api/k8s/clusters/connectivity result these tests mock. Un-skipping them today fails with Unable to find text: Reachable/Unreachable, because the mocked batch probe never reaches the badge.

So re-enabling them means rewriting the tests to drive the reachability registry (seed useTargetConnectivity / its provider), not mocking the old endpoint — and updating the stale label assertions (connected probe → the badge's current label). The k8s-explorer four have separate causes (loading/empty-state timing, OpenShift-context gating) and should each be checked individually.

Acceptance

Each suite's it.skip removed and passing against current component behavior, or — if a test encodes behavior that intentionally no longer exists — deleted with a one-line note rather than left skipped. No it.skip with a stale "needs a mock" TODO left in these three files.

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

    frontendReact/Vite UI (frontend-v2)severity:lowCosmetic, isolated, or self-evident once hittech-debtRefactor or cleanup with no user-visible behaviour changetestingTest suites, fixtures, flakiness, E2E

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions