feat(platform): unify source status tags
This commit is contained in:
@@ -714,6 +714,12 @@ test('shows row service status in dashboard vehicle previews', async () => {
|
||||
phone: '',
|
||||
oem: 'G7s',
|
||||
protocols: ['GB32960', 'JT808'],
|
||||
missingProtocols: ['YUTONG_MQTT'],
|
||||
sourceStatus: [
|
||||
{ protocol: 'GB32960', online: true, lastSeen: '2026-07-03 20:12:10', hasRealtime: true, hasHistory: false, hasRaw: false, hasMileage: false },
|
||||
{ protocol: 'JT808', online: false, lastSeen: '2026-07-03 20:10:00', hasRealtime: true, hasHistory: false, hasRaw: false, hasMileage: false },
|
||||
{ protocol: 'YUTONG_MQTT', online: false, lastSeen: '', hasRealtime: false, hasHistory: false, hasRaw: false, hasMileage: false }
|
||||
],
|
||||
sourceCount: 2,
|
||||
onlineSourceCount: 1,
|
||||
online: true,
|
||||
@@ -791,6 +797,9 @@ test('shows row service status in dashboard vehicle previews', async () => {
|
||||
|
||||
expect(await screen.findByText('VIN-COVERAGE-WARN')).toBeInTheDocument();
|
||||
expect(screen.getAllByText('来源证据').length).toBeGreaterThanOrEqual(1);
|
||||
expect(screen.getByText('GB32960 在线')).toBeInTheDocument();
|
||||
expect(screen.getByText('JT808 离线')).toBeInTheDocument();
|
||||
expect(screen.getByText('YUTONG_MQTT 未接入')).toBeInTheDocument();
|
||||
expect(screen.getAllByText('1/2 来源在线').length).toBeGreaterThanOrEqual(1);
|
||||
expect(screen.getByText('覆盖部分离线')).toBeInTheDocument();
|
||||
expect(screen.getByText('VIN-REALTIME-OFFLINE')).toBeInTheDocument();
|
||||
|
||||
Reference in New Issue
Block a user