24 lines · 831 B · TypeScript
RawDownload
import { describe, expect, it } from "@effect/vitest"; import {  domainLabelFromUrl,  integrationDisplayNameFromUrl,  pascalCaseDomainLabel,} from "./integration-identity"; describe("integration identity URL display names", () => {  it("uses the apex domain label without the public suffix", () => {    expect(domainLabelFromUrl("https://api.example.co.uk/graphql")).toBe("example");  });   it("normalizes domain labels to PascalCase", () => {    expect(pascalCaseDomainLabel("my-api")).toBe("MyApi");  });   it("appends the integration kind to the PascalCase domain label", () => {    expect(integrationDisplayNameFromUrl("https://mcp.linear.app/sse", "MCP")).toBe("Linear MCP");    expect(integrationDisplayNameFromUrl("https://api.shopify.com/graphql", "GraphQL")).toBe(      "Shopify GraphQL",    );  });});

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t