df39d5a16f
Project CI / AI game creator shell Rust shard 1/4 (push) Has been cancelled
Project CI / AI game creator shell Rust shard 2/4 (push) Has been cancelled
Project CI / AI game creator shell Rust shard 3/4 (push) Has been cancelled
Project CI / AI game creator shell Rust shard 4/4 (push) Has been cancelled
Project CI / AI game creator shell Rust smoke (push) Has been cancelled
Project CI / AI game creator shell Rust crates (push) Has been cancelled
Project CI / Backend tests (push) Has been cancelled
Project CI / Native shell tests (push) Has been cancelled
Project CI / Frontend tests (push) Has been cancelled
Project CI / Repository checks (push) Has been cancelled
Project CI / AI game creator shell web tests (push) Has been cancelled
客户端 debug 保留服务器选择,正式包按发布渠道连接服务 修复错误报告时间解析与超时路由脱敏 重做后台错误详情面板并补齐定向测试 同步渠道、诊断与后台展示文档
19 lines
599 B
TypeScript
19 lines
599 B
TypeScript
import { describe, expect, it } from 'vitest';
|
|
|
|
import {
|
|
formatAdminTimestamp,
|
|
parseAdminTimestamp,
|
|
} from './AdminErrorReportsPage';
|
|
|
|
describe('错误报告时间格式化', () => {
|
|
it('解析 SpacetimeDB seconds.microsZ 时间', () => {
|
|
expect(parseAdminTimestamp('1778207451.731746Z')).toBe(1778207451731);
|
|
});
|
|
|
|
it('解析微秒字符串并拒绝无效时间', () => {
|
|
expect(parseAdminTimestamp('1778207451731746')).toBe(1778207451731);
|
|
expect(formatAdminTimestamp('not-a-date')).toBe('-');
|
|
expect(formatAdminTimestamp('999999999999999999999999')).toBe('-');
|
|
});
|
|
});
|