Skip to content

Commit

Permalink
refactor: change the order of import files
Browse files Browse the repository at this point in the history
  • Loading branch information
alisher-epam committed Oct 31, 2023
1 parent 407e3a1 commit 9afb133
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 4 deletions.
4 changes: 2 additions & 2 deletions lib/DonorsList/DonorsContainer.test.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { render, screen } from '@testing-library/react';
import { MemoryRouter } from 'react-router-dom';
import { render, screen } from '@testing-library/react';

import stripesFinalForm from '@folio/stripes/final-form';

Expand All @@ -16,7 +16,7 @@ jest.mock('./DonorsList', () => jest.fn(({ donorsMap }) => {
return 'stripes-components.tableEmpty';
}

return Object.values(donorsMap).map(donor => <div>{donor.name}</div>);
return Object.values(donorsMap).map(({ name }) => <div key={name}>{name}</div>);
}));

jest.mock('./hooks', () => ({
Expand Down
2 changes: 1 addition & 1 deletion lib/DonorsList/DonorsList.test.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { render, screen } from '@testing-library/react';
import { MemoryRouter } from 'react-router-dom';
import { render, screen } from '@testing-library/react';

import DonorsList from './DonorsList';

Expand Down
5 changes: 4 additions & 1 deletion lib/DonorsList/hooks/useFetchDonors/useFetchDonors.test.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
import {
QueryClient,
QueryClientProvider,
} from 'react-query';
import { renderHook } from '@testing-library/react-hooks';
import { QueryClient, QueryClientProvider } from 'react-query';

import { useOkapiKy } from '@folio/stripes/core';

Expand Down

0 comments on commit 9afb133

Please sign in to comment.