feat(platform): sharpen customer vehicle workspace
This commit is contained in:
@@ -597,7 +597,8 @@ test('dashboard presents one vehicle service operating posture', async () => {
|
||||
|
||||
expect(await screen.findByText('车辆服务入口')).toBeInTheDocument();
|
||||
expect(screen.getAllByText('208 / 1,033 在线').length).toBeGreaterThanOrEqual(1);
|
||||
expect(screen.getByText('今日活跃 4')).toBeInTheDocument();
|
||||
expect(screen.getByText('今日活跃')).toBeInTheDocument();
|
||||
expect(screen.getAllByText('4').length).toBeGreaterThanOrEqual(1);
|
||||
expect(screen.getByText('7 告警事件')).toBeInTheDocument();
|
||||
});
|
||||
|
||||
@@ -793,20 +794,26 @@ test('dashboard exposes vehicle data center capability matrix', async () => {
|
||||
};
|
||||
|
||||
await renderDashboard();
|
||||
expect(screen.getByText('车辆运营监控台')).toBeInTheDocument();
|
||||
expect(screen.getByText('先看车辆服务')).toBeInTheDocument();
|
||||
expect(screen.getByText('车辆监控指挥台')).toBeInTheDocument();
|
||||
expect(screen.getByText('车辆服务工作台')).toBeInTheDocument();
|
||||
expect(screen.getByText('先看车在哪里,再看车发生了什么')).toBeInTheDocument();
|
||||
expect(screen.getByText('车辆服务指挥台')).toBeInTheDocument();
|
||||
expect(screen.getByText('全域车辆监控')).toBeInTheDocument();
|
||||
expect(screen.getByText('异常车辆闭环')).toBeInTheDocument();
|
||||
expect(screen.getByText('自定义时间复盘')).toBeInTheDocument();
|
||||
expect(screen.getByText('数据交付与导出')).toBeInTheDocument();
|
||||
expect(screen.getByRole('button', { name: '车辆监控指挥台 全域车辆监控 打开车辆地图' })).toBeInTheDocument();
|
||||
expect(screen.getByRole('button', { name: '车辆监控指挥台 异常车辆闭环 告警事件' })).toBeInTheDocument();
|
||||
expect(screen.getByRole('button', { name: '车辆监控指挥台 自定义时间复盘 轨迹复盘' })).toBeInTheDocument();
|
||||
expect(screen.getByRole('button', { name: '车辆监控指挥台 数据交付与导出 历史导出' })).toBeInTheDocument();
|
||||
expect(screen.getByText('客户常用工作流')).toBeInTheDocument();
|
||||
expect(screen.getByText('实时车辆地图')).toBeInTheDocument();
|
||||
expect(screen.getByText('历史数据导出')).toBeInTheDocument();
|
||||
expect(screen.getByRole('button', { name: '车辆服务指挥台 全域车辆监控 打开车辆地图' })).toBeInTheDocument();
|
||||
expect(screen.getByRole('button', { name: '车辆服务指挥台 异常车辆闭环 告警事件' })).toBeInTheDocument();
|
||||
expect(screen.getByRole('button', { name: '车辆服务指挥台 自定义时间复盘 轨迹复盘' })).toBeInTheDocument();
|
||||
expect(screen.getByRole('button', { name: '车辆服务指挥台 数据交付与导出 历史导出' })).toBeInTheDocument();
|
||||
expect(screen.getByText('客户常用服务')).toBeInTheDocument();
|
||||
expect(screen.getAllByText('车辆地图').length).toBeGreaterThanOrEqual(1);
|
||||
expect(screen.getAllByText('数据导出').length).toBeGreaterThanOrEqual(1);
|
||||
expect(screen.getByText('车辆服务路径')).toBeInTheDocument();
|
||||
expect(screen.getByRole('button', { name: '车辆服务路径 定位车辆 车辆地图' })).toBeInTheDocument();
|
||||
expect(screen.getByRole('button', { name: '车辆服务路径 查看状态 实时监控' })).toBeInTheDocument();
|
||||
expect(screen.getByRole('button', { name: '车辆服务路径 复盘轨迹 轨迹回放' })).toBeInTheDocument();
|
||||
expect(screen.getByRole('button', { name: '车辆服务路径 统计里程 里程统计' })).toBeInTheDocument();
|
||||
expect(screen.getByRole('button', { name: '车辆服务路径 导出交付 数据导出' })).toBeInTheDocument();
|
||||
expect(screen.getByText('今日车辆服务任务板')).toBeInTheDocument();
|
||||
expect(screen.getByText('先看全域在线')).toBeInTheDocument();
|
||||
expect(screen.getByText('再看重点车辆')).toBeInTheDocument();
|
||||
@@ -843,7 +850,7 @@ test('dashboard exposes vehicle data center capability matrix', async () => {
|
||||
expect(screen.getByRole('button', { name: '复制复盘包' })).toBeInTheDocument();
|
||||
expect(screen.getByText('这个范围会同步带入轨迹、里程、历史证据和告警复盘,适合客户问询、BI 核对和异常解释。')).toBeInTheDocument();
|
||||
expect(screen.getByText('查看轨迹')).toBeInTheDocument();
|
||||
expect(screen.getByText('统计里程')).toBeInTheDocument();
|
||||
expect(screen.getAllByText('统计里程').length).toBeGreaterThanOrEqual(1);
|
||||
expect(screen.getByText('导出原始记录')).toBeInTheDocument();
|
||||
expect(screen.getAllByText('轨迹回放').length).toBeGreaterThanOrEqual(1);
|
||||
expect(screen.getByText('里程核对')).toBeInTheDocument();
|
||||
@@ -893,7 +900,7 @@ test('dashboard exposes vehicle data center capability matrix', async () => {
|
||||
expect(writeText).toHaveBeenCalledWith(expect.stringContaining('1. 实时监控'));
|
||||
expect(writeText).toHaveBeenCalledWith(expect.stringContaining('SLA:目标 0-1 秒内进入实时视图'));
|
||||
|
||||
fireEvent.click(screen.getByRole('button', { name: '客户工作流 实时车辆地图' }));
|
||||
fireEvent.click(screen.getByRole('button', { name: '客户工作流 车辆地图' }));
|
||||
expect(window.location.hash).toBe('#/map?online=online');
|
||||
cleanup();
|
||||
|
||||
@@ -915,7 +922,7 @@ test('dashboard exposes vehicle data center capability matrix', async () => {
|
||||
cleanup();
|
||||
|
||||
await renderDashboard();
|
||||
fireEvent.click(screen.getByRole('button', { name: '客户工作流 历史数据导出' }));
|
||||
fireEvent.click(screen.getByRole('button', { name: '客户工作流 数据导出' }));
|
||||
expect(window.location.hash.startsWith('#/history-query')).toBe(true);
|
||||
expect(new URLSearchParams(window.location.hash.split('?')[1] ?? '').get('tab')).toBe('raw');
|
||||
expect(new URLSearchParams(window.location.hash.split('?')[1] ?? '').get('includeFields')).toBe('true');
|
||||
|
||||
Reference in New Issue
Block a user