Skip to content

Commit dc5d30e

Browse files
committed
Improve empty state for test logs
1 parent 23d3243 commit dc5d30e

3 files changed

Lines changed: 26 additions & 6 deletions

File tree

packages/localizations/src/en-US.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -278,12 +278,16 @@ export const enUS: LocalizationResource = {
278278
actionLabel__open: 'Open test URL',
279279
},
280280
testResults: {
281-
title: 'Test results',
281+
title: 'Your test results',
282282
actionLabel__refresh: 'Refresh logs',
283283
polling: 'Waiting for the test run to complete…',
284284
status__success: 'Success',
285285
status__failed: 'Failed',
286286
status__pending: 'Pending',
287+
empty: {
288+
title: 'No test results',
289+
subtitle: 'Use the button above to start running tests',
290+
},
287291
},
288292
testRunDetails: {
289293
title: 'Test run',

packages/shared/src/types/localization.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1349,6 +1349,10 @@ export type __internal_LocalizationResource = {
13491349
status__success: LocalizationValue;
13501350
status__failed: LocalizationValue;
13511351
status__pending: LocalizationValue;
1352+
empty: {
1353+
title: LocalizationValue;
1354+
subtitle: LocalizationValue;
1355+
};
13521356
};
13531357
testRunDetails: {
13541358
title: LocalizationValue;

packages/ui/src/components/ConfigureSSO/steps/TestConfigurationStep.tsx

Lines changed: 17 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,6 @@ export const TestConfigurationStep = (): JSX.Element => {
139139
pageSize={TEST_RUNS_PAGE_SIZE}
140140
totalCount={totalCount ?? 0}
141141
onPageChange={setCurrentPage}
142-
onTestRunCreated={handleTestRunCreated}
143142
/>
144143
</Col>
145144
</Step.Section>
@@ -232,7 +231,6 @@ type TestResultsTableProps = {
232231
rows: EnterpriseConnectionTestRunResource[];
233232
isLoading: boolean;
234233
isPolling: boolean;
235-
onTestRunCreated?: (testUrl: string) => void;
236234
page: number;
237235
pageCount: number;
238236
pageSize: number;
@@ -244,7 +242,6 @@ const TestResultsTable = ({
244242
rows,
245243
isLoading,
246244
isPolling,
247-
onTestRunCreated,
248245
page,
249246
pageCount,
250247
pageSize,
@@ -338,11 +335,26 @@ const TestResultsTable = ({
338335
<Td colSpan={TEST_RESULTS_TABLE_COLUMN_COUNT}>
339336
<Flex
340337
elementDescriptor={descriptors.configureSSOTestResultsEmpty}
338+
direction='col'
341339
align='center'
342340
justify='center'
343-
sx={t => ({ padding: `${t.space.$10} 0`, flex: 1 })}
341+
sx={t => ({
342+
padding: `${t.space.$10} 0`,
343+
flex: 1,
344+
gap: t.space.$1,
345+
textAlign: 'center',
346+
})}
344347
>
345-
<OpenTestUrlButton onTestRunCreated={onTestRunCreated} />
348+
<Text
349+
variant='subtitle'
350+
localizationKey={localizationKeys('configureSSO.testConfigurationStep.testResults.empty.title')}
351+
/>
352+
<Text
353+
colorScheme='secondary'
354+
localizationKey={localizationKeys(
355+
'configureSSO.testConfigurationStep.testResults.empty.subtitle',
356+
)}
357+
/>
346358
</Flex>
347359
</Td>
348360
</Tr>

0 commit comments

Comments
 (0)