feat(ui): add Doctor page (4th destination) — full health snapshot
Composes the platform's health picture in one view: - Summary strip: 4 stat tiles for modules / approvals / audit chain / services with semantic accent colour. - Event-log panel: WORM-1 badge + chain status, points to the first tampered event id when integrity fails. - Modules & approvals panel: counts plus an "attention" pill when approvals are pending. - Services panel: declared services from operator config or a helpful empty-state pointing at ~/.fai/config.yaml. Backed by the new HubAdmin RPCs (VerifyEventChain, ListServices) plus the existing ListCapabilities and ListApprovals. One HubService.doctor() call fans out to all four in parallel. Doctor is the new first destination in the sidebar — that's the page an operator wants to land on after starting the app. Bumps fai_studio 0.3.0 -> 0.4.0. Signed-off-by: flemming-it <stefan.a.flemming@googlemail.com>
This commit is contained in:
parent
c94504247f
commit
4352ecc28c
4 changed files with 520 additions and 3 deletions
|
|
@ -10,13 +10,18 @@ import 'package:flutter_test/flutter_test.dart';
|
|||
import 'package:fai_studio/main.dart';
|
||||
|
||||
void main() {
|
||||
testWidgets('Studio shell shows the three MVP destinations',
|
||||
testWidgets('Studio shell shows the four destinations',
|
||||
(tester) async {
|
||||
await tester.pumpWidget(const StudioApp());
|
||||
|
||||
expect(find.text('F∆I Studio'), findsOneWidget);
|
||||
// "Doctor" appears twice (sidebar label + app bar title of the
|
||||
// first selected page) — same for "Modules" / "Audit" /
|
||||
// "Approvals" once their pages are first visited. We just check
|
||||
// the labels are findable at all.
|
||||
expect(find.text('Doctor'), findsWidgets);
|
||||
expect(find.text('Modules'), findsWidgets);
|
||||
expect(find.text('Audit'), findsOneWidget);
|
||||
expect(find.text('Approvals'), findsOneWidget);
|
||||
expect(find.text('Audit'), findsWidgets);
|
||||
expect(find.text('Approvals'), findsWidgets);
|
||||
});
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue