Skip to content

Commit

Permalink
fix lint issue
Browse files Browse the repository at this point in the history
  • Loading branch information
usavkov-epam committed Nov 24, 2023
1 parent 6d07f35 commit 3cade37
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ const CUSTOM_SORT_MAP = {
};

export const useBuildQuery = () => {
const stripes = useStripes()
const stripes = useStripes();

return useCallback(makeQueryBuilder(

Check warning on line 20 in src/Organizations/OrganizationsList/hooks/useBuildQuery/useBuildQuery.js

View workflow job for this annotation

GitHub Actions / github-actions-ci

React Hook useCallback received a function whose dependencies are unknown. Pass an inline function instead

Check warning on line 20 in src/Organizations/OrganizationsList/hooks/useBuildQuery/useBuildQuery.js

View workflow job for this annotation

GitHub Actions / github-actions-ci

React Hook useCallback received a function whose dependencies are unknown. Pass an inline function instead
'cql.allRecords=1',
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
import queryString from 'query-string';

import { renderHook } from '@folio/jest-config-stripes/testing-library/react';
import { useStripes } from '@folio/stripes/core';
import {
Expand Down Expand Up @@ -30,13 +28,15 @@ describe('useBuildQuery', () => {
it('should return function, that return query', () => {
const { result } = renderHook(() => useBuildQuery());

expect(result.current(queryString.parse('?foo=bar'))).toBe('(foo=="bar") sortby name/sort.ascending');
expect(result.current({
[SEARCH_PARAMETER]: 'bar',
[SEARCH_INDEX_PARAMETER]: 'foo',
})).toBe('(((foo=bar*))) sortby name/sort.ascending');
});

describe('Banking information', () => {
const params = {
[SEARCH_PARAMETER]: 'qwerty',
[SEARCH_INDEX_PARAMETER]: 'name',
};

it('should include banking information index in the query if a user has the appropriate permission', () => {
Expand Down

0 comments on commit 3cade37

Please sign in to comment.