| ... | @@ -1,15 +1,8 @@ | ... | @@ -1,15 +1,8 @@ |
| 1 | import { describe, expect, it } from "vite-plus/test"; | 1 | import { describe, expect, it } from "vite-plus/test"; |
| 2 | | 2 | |
| 3 | import { openOnHostLabel, pullRequestLinkContextMenuItems } from "./pullRequestLinkContextMenu"; | 3 | import { openOnHostLabel } from "./pullRequestLinkContextMenu"; |
| 4 | | 4 | |
| 5 | describe("pull request link context menu", () => { | 5 | describe("pull request link context menu", () => { |
| 6 | it("offers the copy first and the host's own page after it", () => { | | |
| 7 | expect(pullRequestLinkContextMenuItems("Open on GitHub")).toEqual([ | | |
| 8 | { id: "copy-link", label: "Copy link", icon: "copy" }, | | |
| 9 | { id: "open-external", label: "Open on GitHub" }, | | |
| 10 | ]); | | |
| 11 | }); | | |
| 12 | | | |
| 13 | it("names every host it knows, and says nothing false about one it does not", () => { | 6 | it("names every host it knows, and says nothing false about one it does not", () => { |
| 14 | expect(openOnHostLabel("github")).toBe("Open on GitHub"); | 7 | expect(openOnHostLabel("github")).toBe("Open on GitHub"); |
| 15 | expect(openOnHostLabel("gitlab")).toBe("Open on GitLab"); | 8 | expect(openOnHostLabel("gitlab")).toBe("Open on GitLab"); |