/**
 * Test helpers for creating NextRequest instances
 */

import { NextRequest } from "next/server";

/**
 * Create a mock NextRequest for testing
 */
export function createMockRequest(
  url: string,
  options: {
    method?: string;
    body?: any;
    headers?: Record<string, string>;
  } = {},
): NextRequest {
  const { method = "GET", body, headers = {} } = options;

  const requestInit: RequestInit = {
    method,
    headers: {
      "Content-Type": "application/json",
      ...headers,
    },
  };

  if (body) {
    requestInit.body = JSON.stringify(body);
  }

  return new NextRequest(url, requestInit);
}

// Dummy test to satisfy Jest requirement that test files have at least one test
describe("Helper Module", () => {
  it("should export utilities", () => {
    expect(true).toBe(true);
  });
});
