import { describe, test } from "bun:test";

// Side-effect-free imports so Bun's coverage reporter includes Phase-1 and Phase-2
// modules even when individual test files haven't been added yet.
// Files handled by Phases 3-4 live under coveragePathIgnorePatterns in bunfig.toml.

import "@/core/constants.js";
import "@/core/errors.js";
import "@/utils/slug.js";
import "@/utils/ansi.js";
import "@/utils/git-remote.js";
import "@/utils/timezone.js";
import "@/utils/log-line.js";
import "@/utils/node-version.js";
import "@/utils/package-manager.js";
import "@/utils/logger.js";
import "@/utils/codeartifact.js";
import "@/utils/config.js";
import "@/datadog/format.js";
import "@/pipeline/safety.js";
import "@/pipeline/label-resolver.js";
import "@/pipeline/review-ticket-pipeline.js";
import "@/utils/readiness-display.js";
import "@/jira/schemas.js";
import "@/agent/prompts.js";
import "@/repo/selector.js";
import "@/repo/registry.js";
import "@/queue/memory-queue.js";
import "@/pr-memory/store.js";
import "@/slack/message-store.js";
import "@/scheduler/daily-report-store.js";
import "@/scheduler/prompt-cleanup.js";
import "@/server/middleware/validate.js";
import "@/server/routes/health.js";
import "@/server/routes/webhook.js";
import "@/poller/comment-filter.js";
import "@/poller/ticket-review-processed.js";
// Phase 2: external HTTP / SDK clients
import "@/jira/client.js";
import "@/github/client.js";
import "@/github/auth.js";
import "@/slack/client.js";
import "@/datadog/client.js";
import "@/agent/cursor-cli-client.js";
import "@/agent/cursor-cloud-client.js";
import "@/utils/jira-attachments.js";
import "@/poller/pr-mention-poller.js";
// Phase 4: pipelines, scheduler, server (covered by dedicated test files)
import "@/pipeline/slack-mention-pipeline.js";
import "@/pipeline/pr-comment-pipeline.js";
import "@/pipeline/pr-mention-pipeline.js";
import "@/pipeline/fix-pipeline.js";
import "@/scheduler/daily-report.js";
import "@/server/app.js";
import "@/server/routes/debug.js";

describe("coverage sentinel", () => {
  test("all Phase-1 through Phase-4 modules import without side effects", () => {
    // Successful imports are the assertion. Explicit test keeps bun:test happy.
  });
});
