mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
Chore: Convert KeyValuesTable to RTL (#51278)
* Convert KeyValuesTable to RTL * Update data-testid * Update data-testid * Convert KeyValuesTable to RTL Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
This commit is contained in:
@@ -119,21 +119,21 @@ describe('TraceView', () => {
|
||||
const firstSpan = screen.getAllByText('', { selector: 'div[data-testid="span-view"]' })[0];
|
||||
await userEvent.click(firstSpan);
|
||||
await userEvent.click(screen.getByText(/Process/));
|
||||
table = screen.getByText('', { selector: 'div[data-test-id="KeyValueTable"]' });
|
||||
table = screen.getByText('', { selector: 'div[data-testid="KeyValueTable"]' });
|
||||
expect(table.innerHTML).toContain('client-uuid-1');
|
||||
await userEvent.click(firstSpan);
|
||||
|
||||
const secondSpan = screen.getAllByText('', { selector: 'div[data-testid="span-view"]' })[1];
|
||||
await userEvent.click(secondSpan);
|
||||
await userEvent.click(screen.getByText(/Process/));
|
||||
table = screen.getByText('', { selector: 'div[data-test-id="KeyValueTable"]' });
|
||||
table = screen.getByText('', { selector: 'div[data-testid="KeyValueTable"]' });
|
||||
expect(table.innerHTML).toContain('client-uuid-2');
|
||||
await userEvent.click(secondSpan);
|
||||
|
||||
const thirdSpan = screen.getAllByText('', { selector: 'div[data-testid="span-view"]' })[2];
|
||||
await userEvent.click(thirdSpan);
|
||||
await userEvent.click(screen.getByText(/Process/));
|
||||
table = screen.getByText('', { selector: 'div[data-test-id="KeyValueTable"]' });
|
||||
table = screen.getByText('', { selector: 'div[data-testid="KeyValueTable"]' });
|
||||
expect(table.innerHTML).toContain('client-uuid-3');
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user