From e54f94447298f3e7834912d0c160cedee3e2ebf3 Mon Sep 17 00:00:00 2001 From: devinleighsmith Date: Fri, 3 Nov 2023 17:53:09 -0700 Subject: [PATCH] test corrections. --- .../properties/filter/PropertyFilter.test.tsx | 13 ++----------- .../__snapshots__/PropertyListView.test.tsx.snap | 3 ++- 2 files changed, 4 insertions(+), 12 deletions(-) diff --git a/source/frontend/src/features/properties/filter/PropertyFilter.test.tsx b/source/frontend/src/features/properties/filter/PropertyFilter.test.tsx index 605d2cfc01..210c521ee0 100644 --- a/source/frontend/src/features/properties/filter/PropertyFilter.test.tsx +++ b/source/frontend/src/features/properties/filter/PropertyFilter.test.tsx @@ -112,7 +112,7 @@ describe('MapFilterBar', () => { expect(container.firstChild).toMatchSnapshot(); }); - it('submits correct values', async () => { + it('does not submit if there is no pid/pin for address', async () => { // Arrange mockKeycloak(['admin-properties']); @@ -128,16 +128,7 @@ describe('MapFilterBar', () => { }); // Assert - expect(onFilterChange).toBeCalledWith({ - address: '', - latitude: '', - longitude: '', - page: undefined, - pinOrPid: '', - planNumber: '', - quantity: undefined, - searchBy: 'pinOrPid', - }); + expect(onFilterChange).not.toHaveBeenCalled(); }); it('resets values when reset button is clicked', async () => { diff --git a/source/frontend/src/features/properties/list/__snapshots__/PropertyListView.test.tsx.snap b/source/frontend/src/features/properties/list/__snapshots__/PropertyListView.test.tsx.snap index 0b247b02a5..d893ff1082 100644 --- a/source/frontend/src/features/properties/list/__snapshots__/PropertyListView.test.tsx.snap +++ b/source/frontend/src/features/properties/list/__snapshots__/PropertyListView.test.tsx.snap @@ -363,8 +363,9 @@ exports[`Property list view matches snapshot 1`] = ` class="col-auto" >