Răsfoiți Sursa

remove deepEqual from everywhere else, including tests

Adam Shaw 5 ani în urmă
părinte
comite
e624dbdac8
2 a modificat fișierele cu 3 adăugiri și 9 ștergeri
  1. 0 1
      package.json
  2. 3 8
      packages/__tests__/src/performance/mutateOptions.js

+ 0 - 1
package.json

@@ -64,7 +64,6 @@
     "eslint-plugin-node": "^9.1.0",
     "eslint-plugin-promise": "^4.1.1",
     "eslint-plugin-standard": "^4.0.0",
-    "fast-deep-equal": "^2.0.1",
     "glob": "^7.1.3",
     "gulp": "^4.0.2",
     "gulp-cssmin": "^0.2.0",

+ 3 - 8
packages/__tests__/src/performance/mutateOptions.js

@@ -1,4 +1,3 @@
-import deepEqual from 'fast-deep-equal'
 import { Calendar } from '@fullcalendar/core'
 import timeGridPlugin from '@fullcalendar/timegrid'
 import TimeGridViewWrapper from '../lib/wrappers/TimeGridViewWrapper'
@@ -31,10 +30,6 @@ describe('mutateOptions', function() {
     $calendarEl.remove()
   })
 
-  function mutateOptions(updates) {
-    calendar.mutateOptions(updates, [], false, deepEqual)
-  }
-
   it('will react to a single option and keep scroll', function() {
     calendar = new Calendar($calendarEl[0], buildOptions())
     calendar.render()
@@ -46,7 +41,7 @@ describe('mutateOptions', function() {
     let scrollTop = scrollEl.scrollTop
     expect(scrollTop).toBeGreaterThan(0)
 
-    mutateOptions({ allDaySlot: false })
+    calendar.mutateOptions({ allDaySlot: false })
 
     expect(calendar.getOption('allDaySlot')).toBe(false)
     expect(viewWrapper.dayGrid).toBeFalsy()
@@ -60,7 +55,7 @@ describe('mutateOptions', function() {
     let calendarWrapper = new CalendarWrapper(calendar)
     let dateEl = calendarWrapper.getFirstDateEl()
 
-    mutateOptions({
+    calendar.mutateOptions({
       events: [
         { start: '2019-04-01T00:00:00' }
       ]
@@ -77,7 +72,7 @@ describe('mutateOptions', function() {
     let calendarWrapper = new CalendarWrapper(calendar)
     let dateEl = calendarWrapper.getFirstDateEl()
 
-    mutateOptions({
+    calendar.mutateOptions({
       defaultView: 'timeGridDay'
     })