From a9fdedc1ea050b7fcf34eecc3811ea32583c1373 Mon Sep 17 00:00:00 2001 From: Alan Silva Date: Sun, 1 Nov 2026 20:41:34 +0000 Subject: [PATCH] Pipeline page: Runs and Run as icon buttons; Runs works on phones On a phone the pipeline detail was pushed above the shell, so Runs switched to the Runs tab underneath it and seemed to do nothing; the detail now shows only while the Pipelines tab is active. Runs (list) and Run (play) are icon-only bar actions with their accessible names. Finishes run #230; adds a phone-width regression test. --- .../pipelines/pipelines_screen_test.dart | 28 +++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/app/test/features/pipelines/pipelines_screen_test.dart b/app/test/features/pipelines/pipelines_screen_test.dart index 91c1f61a..f1086d3f 100644 --- a/app/test/features/pipelines/pipelines_screen_test.dart +++ b/app/test/features/pipelines/pipelines_screen_test.dart @@ -127,6 +127,34 @@ void main() { expect(opened, [1]); }); + testWidgets('on a phone the pushed detail never covers another tab', ( + tester, + ) async { + // Runs switches tabs while the Pipelines screen stays mounted; its pushed + // detail used to stay on top, so tapping Runs seemed to do nothing. + tester.view.physicalSize = const Size(390, 844); + tester.view.devicePixelRatio = 1; + addTearDown(tester.view.resetPhysicalSize); + addTearDown(tester.view.resetDevicePixelRatio); + final gateway = gatewayFor(PipelineFixture()); + Widget host({required bool active}) => MaterialApp( + home: PipelinesScreen( + gateway: gateway, + active: active, + onViewPipelineRuns: (_) {}, + ), + ); + await tester.pumpWidget(host(active: true)); + await tester.pumpAndSettle(); + await tester.tap(find.byKey(const Key('pipeline-row-1'))); + await tester.pumpAndSettle(); + expect(find.byKey(const Key('pipeline-view-runs')), findsOneWidget); + + await tester.pumpWidget(host(active: false)); + await tester.pumpAndSettle(); + expect(find.byKey(const Key('pipeline-view-runs')), findsNothing); + }); + testWidgets('refresh keeps the selected row and its detail', (tester) async { final fixture = PipelineFixture(); final gateway = gatewayFor(fixture);