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.
This commit is contained in:
2026-11-01 20:41:34 +00:00
parent f8903e2f6d
commit a9fdedc1ea
@@ -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);