Skip to content

Commit

Permalink
[Stack Monitoring] fix beats pages test-subj attributes (elastic#114835
Browse files Browse the repository at this point in the history
…) (elastic#115138)

* fix beats pages test-subj attributes

* fix eslint errors

Co-authored-by: Kevin Lacabane <kevin.lacabane@elastic.co>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
  • Loading branch information
3 people authored Oct 15, 2021
1 parent e35e1a4 commit cfa2df7
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 13 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -23,13 +23,15 @@ export const BeatsTemplate: React.FC<BeatsTemplateProps> = ({ instance, ...props
defaultMessage: 'Overview',
}),
route: '/beats',
testSubj: 'beatsOverviewPage',
});
tabs.push({
id: 'instances',
label: i18n.translate('xpack.monitoring.beatsNavigation.instancesLinkText', {
defaultMessage: 'Instances',
}),
route: '/beats/beats',
testSubj: 'beatsListingPage',
});
} else {
tabs.push({
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,12 +71,7 @@ export const BeatsInstancesPage: React.FC<ComponentProps> = ({ clusters }) => {
]);

return (
<BeatsTemplate
title={title}
pageTitle={pageTitle}
getPageData={getPageData}
data-test-subj="beatsListingPage"
>
<BeatsTemplate title={title} pageTitle={pageTitle} getPageData={getPageData}>
<div data-test-subj="monitoringBeatsInstancesApp">
<SetupModeRenderer
productName={BEATS_SYSTEM_ID}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,13 +72,8 @@ export const BeatsOverviewPage: React.FC<ComponentProps> = ({ clusters }) => {
};

return (
<BeatsTemplate
title={title}
pageTitle={pageTitle}
getPageData={getPageData}
data-test-subj="beatsOverviewPage"
>
<div data-test-subj="beatsOverviewPage">{renderOverview(data)}</div>
<BeatsTemplate title={title} pageTitle={pageTitle} getPageData={getPageData}>
<div>{renderOverview(data)}</div>
</BeatsTemplate>
);
};

0 comments on commit cfa2df7

Please sign in to comment.