дзеркало
https://github.com/l0ng-ai/openidea.git
синхронізовано 2026-11-08 19:02:17 +02:00
Go files showed no semantic colours because gopls semantic tokens were not requested, and Color Scheme had no Go page. gopls is now initialised with semantic tokens, constants, package variables and package references get Go-specific roles, and Color Scheme has a Go page with a preview. Siblings covered: Go-specific attributes inherit from Language Defaults, Reset restores them, Chinese labels show in the Color Scheme tree, and a user's own gopls settings are kept. Co-authored-by: shohruh-genius <[email protected]>
11 рядки
569 B
TypeScript
11 рядки
569 B
TypeScript
import { expect, test } from "@playwright/test";
|
|
|
|
test("gopls constants and globals use the Go scheme attributes", async ({ page }) => {
|
|
await page.goto("/e2e/goHighlight.html");
|
|
await expect(page.locator(".cm-sem-constant")).toHaveText("Limit");
|
|
await expect(page.locator(".cm-sem-constant")).toHaveCSS("color", "rgb(34, 68, 102)");
|
|
await expect(page.locator(".cm-sem-global")).toHaveText("Global");
|
|
await expect(page.locator(".cm-sem-global")).toHaveCSS("color", "rgb(51, 85, 119)");
|
|
await expect(page.locator(".cm-sem-namespace")).toHaveText("fmt");
|
|
});
|