镜像自地址
https://github.com/lhly/cloud-drive-renamer.git
已同步 2026-10-21 06:01:51 +08:00
新增 UC 网盘适配器,包括页面脚本注入、API 调用、错误处理和完整的重命名工作流。同时将包管理器从 npm 迁移至 pnpm,更新 CI/CD 工作流、文档和锁文件,并扩展权限范围以支持 UC 网盘域名。
14 行
456 B
TypeScript
14 行
456 B
TypeScript
import { describe, expect, it } from 'vitest';
|
|
import { markUCPageScriptReady } from '../../../src/adapters/uc/page-script';
|
|
|
|
describe('UC page script ready flag', () => {
|
|
it('does not throw when document.body is temporarily unavailable', () => {
|
|
const body = document.body;
|
|
document.documentElement.removeChild(body);
|
|
|
|
expect(() => markUCPageScriptReady(Date.now())).not.toThrow();
|
|
|
|
document.documentElement.appendChild(body);
|
|
});
|
|
});
|