diff --git a/web/client/actions/__tests__/catalog-test.js b/web/client/actions/__tests__/catalog-test.js index f93c6839fd..029e2aa4bc 100644 --- a/web/client/actions/__tests__/catalog-test.js +++ b/web/client/actions/__tests__/catalog-test.js @@ -153,7 +153,7 @@ describe('Test correctness of the catalog actions', () => { expect(retval.service).toBe(service); }); it('deleteService', () => { - var retval = deleteService(status); + var retval = deleteService(); expect(retval).toExist(); expect(retval.type).toBe(DELETE_SERVICE); diff --git a/web/client/plugins/__tests__/DrawerMenu-test.jsx b/web/client/plugins/__tests__/DrawerMenu-test.jsx index c64b1d09d5..05a59a03e4 100644 --- a/web/client/plugins/__tests__/DrawerMenu-test.jsx +++ b/web/client/plugins/__tests__/DrawerMenu-test.jsx @@ -28,9 +28,12 @@ const SAMPLE_ITEM = { const mouseMove = (x, y, node) => { const doc = node ? node.ownerDocument : document; - const evt = doc.createEvent('MouseEvents'); - evt.initMouseEvent('mousemove', true, true, window, - 0, 0, 0, x, y, false, false, false, false, 0, null); + const evt = new MouseEvent( + 'mousemove', + { + canBubble: true, cancelable: true, view: window, detail: 0, screenX: 0, screenY: 0, clientX: x, clientY: y, + ctrlKey: false, altKey: false, shiftKey: false, metaKey: false, button: 0, relatedTarget: null + }); doc.dispatchEvent(evt); return evt; }; diff --git a/web/client/plugins/mapEditor/enhancers/editor.js b/web/client/plugins/mapEditor/enhancers/editor.js index 4b33a2fd5a..862a9446f9 100644 --- a/web/client/plugins/mapEditor/enhancers/editor.js +++ b/web/client/plugins/mapEditor/enhancers/editor.js @@ -22,7 +22,6 @@ import {backgroundListSelector} from '../../../selectors/backgroundselector'; import {mapOptionsToSaveSelector} from '../../../selectors/mapsave'; import {textSearchConfigSelector, bookmarkSearchConfigSelector} from '../../../selectors/searchconfig'; import MapUtils from '../../../utils/MapUtils'; -import { isNull } from 'util'; const saveSelector = createSelector( @@ -52,7 +51,7 @@ export default compose( const mapData = MapUtils.saveMapConfiguration(map, layers, groups, backgrounds, textSearchConfig, bookmarkSearchConfig, additionalOptions); - return save({...mapData.map, layers: mapData.map.layers.map(l => pickBy(l, (p) => p !== undefined && !isNull(p)))}, owner); + return save({...mapData.map, layers: mapData.map.layers.map(l => pickBy(l, (p) => p !== undefined && !(p === null)))}, owner); } }), WithConfirm,