import { expect } from "e2e";
import { test, WEB } from "./t3.ts";

test("Automatic title keeps the Indic conjunct whole", WEB, async ({t3, app, screen, browser}) => {
  const project = await t3.project("demo");
  await t3.open();
  await screen.getByRole("textbox", "Message New thread").waitFor();
  await screen.getByRole("button", "Showcase", {exact:true}).tap();
  await screen.getByPlaceholder("Search models...").fill("Showcase");
  await screen.getByRole("option", /^Showcase/).tap();
  await browser.keyboard.press("Escape");
  await screen.getByRole("textbox").fill("Please review the changes we made in the module क्षमा before publishing the release notes");
  await browser.keyboard.press("Enter");
  await screen.getByRole("heading", /^Please review the changes we made in the module/).waitFor();
  await app.screenshot("automatic-indic-title");
  await expect(screen.getByRole("heading", /^Please review the changes we made in the module/)).toHaveText("Please review the changes we made in the module...");
});
