Skip to content

Commit

Permalink
correct variable names
Browse files Browse the repository at this point in the history
  • Loading branch information
kevinlog committed Jun 29, 2020
1 parent 6584b38 commit a8d49c2
Showing 1 changed file with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -410,10 +410,10 @@ describe('when on the hosts page', () => {
it('should include the link to reassignment in Ingest', async () => {
coreStart.application.getUrlForApp.mockReturnValue('/app/ingestManager');
const renderResult = render();
const linkToLogs = await renderResult.findByTestId('hostDetailsLinkToIngest');
expect(linkToLogs).not.toBeNull();
expect(linkToLogs.textContent).toEqual('Reassign Policy');
expect(linkToLogs.getAttribute('href')).toEqual(
const linkToReassign = await renderResult.findByTestId('hostDetailsLinkToIngest');
expect(linkToReassign).not.toBeNull();
expect(linkToReassign.textContent).toEqual('Reassign Policy');
expect(linkToReassign.getAttribute('href')).toEqual(
`/app/ingestManager#/fleet/agents/${agentId}/activity?openReassignFlyout=true`
);
});
Expand All @@ -422,9 +422,9 @@ describe('when on the hosts page', () => {
beforeEach(async () => {
coreStart.application.getUrlForApp.mockReturnValue('/app/ingestManager');
const renderResult = render();
const linkToLogs = await renderResult.findByTestId('hostDetailsLinkToIngest');
const linkToReassign = await renderResult.findByTestId('hostDetailsLinkToIngest');
reactTestingLibrary.act(() => {
reactTestingLibrary.fireEvent.click(linkToLogs);
reactTestingLibrary.fireEvent.click(linkToReassign);
});
});

Expand Down

0 comments on commit a8d49c2

Please sign in to comment.