Skip to content

Commit

Permalink
Fixed test import
Browse files Browse the repository at this point in the history
  • Loading branch information
Liza K committed Nov 10, 2019
1 parent df52a14 commit 6c7056e
Showing 1 changed file with 10 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -225,17 +225,23 @@ describe('filter_manager', () => {
});

test('mixed filters: global filters should stay in the beginning', async () => {
const f1 = getFilter(FilterStateStore.GLOBAL_STATE, false, false, 'age', 34);
const f2 = getFilter(FilterStateStore.APP_STATE, false, false, 'gender', 'female');
const f1 = getFilter(esFilters.FilterStateStore.GLOBAL_STATE, false, false, 'age', 34);
const f2 = getFilter(esFilters.FilterStateStore.APP_STATE, false, false, 'gender', 'female');
filterManager.addFilters([f1, f2]);
const filters = filterManager.getFilters();
expect(filters).toHaveLength(2);
expect(filters).toEqual([f1, f2]);
});

test('mixed filters: global filters should move to the beginning', async () => {
const f1 = getFilter(FilterStateStore.APP_STATE, false, false, 'age', 34);
const f2 = getFilter(FilterStateStore.GLOBAL_STATE, false, false, 'gender', 'female');
const f1 = getFilter(esFilters.FilterStateStore.APP_STATE, false, false, 'age', 34);
const f2 = getFilter(
esFilters.FilterStateStore.GLOBAL_STATE,
false,
false,
'gender',
'female'
);
filterManager.addFilters([f1, f2]);
const filters = filterManager.getFilters();
expect(filters).toHaveLength(2);
Expand Down

0 comments on commit 6c7056e

Please sign in to comment.