Skip to content

Commit 92d44a9

Browse files
committed
feat(test): put test suite cards in a scrollable list view
1 parent e7e7964 commit 92d44a9

File tree

1 file changed

+19
-12
lines changed

1 file changed

+19
-12
lines changed

lib/pages/testing/testing_view.dart

Lines changed: 19 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -182,18 +182,25 @@ class _TestingViewState extends ConsumerState<TestingView> {
182182
const SizedBox(height: 16),
183183

184184
// Integration test suite cards.
185-
...IntegrationTestType.values.map((type) {
186-
return Padding(
187-
padding: const EdgeInsets.only(bottom: 8),
188-
child: TestSuiteCard(
189-
testType: type,
190-
status: testingState.testStatuses[type] ?? TestSuiteStatus.waiting,
191-
onTap: testingState.isRunning
192-
? null
193-
: () => testingService.runTestSuite(type),
194-
),
195-
);
196-
}),
185+
SizedBox(
186+
height: 300, // Set a fixed height for the scrollable area.
187+
child: ListView.builder(
188+
itemCount: IntegrationTestType.values.length,
189+
itemBuilder: (context, index) {
190+
final type = IntegrationTestType.values[index];
191+
return Padding(
192+
padding: const EdgeInsets.only(bottom: 8),
193+
child: TestSuiteCard(
194+
testType: type,
195+
status: testingState.testStatuses[type] ?? TestSuiteStatus.waiting,
196+
onTap: testingState.isRunning
197+
? null
198+
: () => testingService.runTestSuite(type),
199+
),
200+
);
201+
},
202+
),
203+
),
197204
const SizedBox(height: 16),
198205

199206
// SWB button.

0 commit comments

Comments
 (0)