Skip to content

Commit

Permalink
fix jest test
Browse files Browse the repository at this point in the history
  • Loading branch information
Michail Yasonik committed Dec 9, 2020
1 parent a492e58 commit accb37f
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ jest.mock('../../app_links', () => ({
jest.mock('../../context', () => ({
useKibana: jest.fn().mockReturnValue({
services: {
application: { capabilities: { advancedSettings: { show: true } } },
application: { capabilities: { advancedSettings: { show: true, save: true } } },
notifications: { toast: { addSuccess: jest.fn() } },
},
}),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ interface Props {
path: string;
/** Callback function to invoke when the user wants to set their default route to the current page */
onSetDefaultRoute?: (event: MouseEvent) => void;
/** Callback function to invoke when the user wants to change their default route button is changed */
/** Callback function to invoke when the user wants to change their default route button is changed */
onChangeDefaultRoute?: (event: MouseEvent) => void;
}

Expand All @@ -53,7 +53,7 @@ export const OverviewPageFooter: FC<Props> = ({
const { show, save } = application.capabilities.advancedSettings;
if (!show && !save) return <></>;

const defaultRoutebutton = defaultRoute.includes(path) ? (
const defaultRouteButton = defaultRoute.includes(path) ? (
<RedirectAppLinks application={application}>
<EuiButtonEmpty
className="kbnOverviewPageFooter__button"
Expand Down Expand Up @@ -102,7 +102,7 @@ export const OverviewPageFooter: FC<Props> = ({
<footer className="kbnOverviewPageFooter">
<EuiFlexGroup justifyContent="spaceBetween">
<EuiFlexItem grow={false}>
<div>{defaultRoutebutton}</div>
<div>{defaultRouteButton}</div>
</EuiFlexItem>
</EuiFlexGroup>
</footer>
Expand Down

0 comments on commit accb37f

Please sign in to comment.