Skip to content

Commit

Permalink
[Fleet] Enable agent upgrade tooltip (elastic#168638)
Browse files Browse the repository at this point in the history
## Summary

Followup to elastic#167539.

Closes elastic/ingest-dev#2568.

As the version on which agents will have upgrade details is not known
yet, we decided to defer showing the tooltip for agents that don't until
it is (cf.
elastic#167539 (comment)).

This PR sets the version to 8.12.

Co-authored-by: Kibana Machine <[email protected]>
  • Loading branch information
jillguyonnet and kibanamachine authored Nov 21, 2023
1 parent 10ec713 commit e859b14
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -244,8 +244,7 @@ describe('AgentUpgradeStatus', () => {
expect(results.queryAllByText('Info')).toEqual([]);
});

// Unskip this test when minVersion is set.
it.skip('should render an icon with tooltip if the agent is upgrading', async () => {
it('should render an icon with tooltip if the agent is upgrading', async () => {
const results = render({
agentUpgradeStartedAt: '2023-10-03T14:34:12Z',
agentUpgradedAt: null,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -225,7 +225,7 @@ export const AgentUpgradeStatus: React.FC<{
[agentUpgradeStartedAt, agentUpgradedAt]
);
const status = useMemo(() => getStatusComponents(agentUpgradeDetails), [agentUpgradeDetails]);
const minVersion = undefined; // Change this to a string in order for a tooltip to render for upgrading agents with no upgrade details.
const minVersion = '8.12';

if (isAgentUpgradable) {
return (
Expand All @@ -249,7 +249,7 @@ export const AgentUpgradeStatus: React.FC<{
);
}

if (minVersion && isAgentUpgrading) {
if (isAgentUpgrading) {
return (
<EuiIconTip
type="iInCircle"
Expand Down

0 comments on commit e859b14

Please sign in to comment.