16 lines
721 B
TypeScript
16 lines
721 B
TypeScript
import assert from "node:assert/strict";
|
|
import { readFileSync } from "node:fs";
|
|
import test from "node:test";
|
|
|
|
const panel = readFileSync(new URL("../src/components/profile-panel.tsx", import.meta.url), "utf8");
|
|
|
|
test("the profile pane keeps avatar palettes and drops the duplicate chart-library button", () => {
|
|
assert.doesNotMatch(panel, /管理星盘资料/);
|
|
assert.match(panel, /role="radiogroup"/);
|
|
assert.match(panel, /换一个形象/);
|
|
// 原值:48px;新值:56px;原因:设置面板的头像预览需要更清晰的视觉锚点,并与账户身份区留出稳定间距。
|
|
assert.match(panel, /size=\{56\}/);
|
|
assert.match(panel, /账户信息/);
|
|
assert.match(panel, /登录邮箱/);
|
|
});
|