mirror of
https://github.com/grafana/grafana.git
synced 2025-02-15 10:03:33 -06:00
Frontend: Migrate PageToolbar.tsx
from aria-label e2e selectors to data-testid (#79663)
* refactor: update PageToolbar to use data-testid * refactor: update selector text --------- Co-authored-by: joshhunt <josh@trtr.co>
This commit is contained in:
parent
5154a9d99c
commit
576b8ccff6
@ -656,9 +656,6 @@ exports[`better eslint`] = {
|
||||
[0, 0, 0, "Unexpected any. Specify a different type.", "2"],
|
||||
[0, 0, 0, "Unexpected any. Specify a different type.", "3"]
|
||||
],
|
||||
"packages/grafana-ui/src/components/PageLayout/PageToolbar.tsx:5381": [
|
||||
[0, 0, 0, "Use data-testid for E2E selectors instead of aria-label", "0"]
|
||||
],
|
||||
"packages/grafana-ui/src/components/PanelChrome/LoadingIndicator.tsx:5381": [
|
||||
[0, 0, 0, "Use data-testid for E2E selectors instead of aria-label", "0"]
|
||||
],
|
||||
|
@ -287,7 +287,7 @@ export const Components = {
|
||||
button: (title: string) => `QueryEditor toolbar item button ${title}`,
|
||||
},
|
||||
BackButton: {
|
||||
backArrow: 'Go Back',
|
||||
backArrow: 'data-testid Go Back',
|
||||
},
|
||||
OptionsGroup: {
|
||||
group: (title?: string) => (title ? `Options group ${title}` : 'Options group'),
|
||||
|
@ -92,7 +92,7 @@ export const PageToolbar = React.memo(
|
||||
tooltip="Go back (Esc)"
|
||||
tooltipPlacement="bottom"
|
||||
size="xxl"
|
||||
aria-label={selectors.components.BackButton.backArrow}
|
||||
data-testid={selectors.components.BackButton.backArrow}
|
||||
onClick={onGoBack}
|
||||
/>
|
||||
</div>
|
||||
|
Loading…
Reference in New Issue
Block a user