Эх сурвалжийг харах

Merge pull request #17189 from overleaf/revert-17184-msm-run-all-fake-timers

Revert "[web] Run fake timers with runAll() instead of next()"

GitOrigin-RevId: 878e18275e3b65cccc1441de4fe647601b5c6321
Miguel Serrano 2 жил өмнө
parent
commit
eadbe8cddc

+ 2 - 2
services/web/test/unit/src/ThirdPartyDataStore/TpdsUpdateHandlerTests.js

@@ -504,7 +504,7 @@ function expectProjectCreated() {
 
 
   it('sets the root doc', function () {
   it('sets the root doc', function () {
     // Fire pending timers
     // Fire pending timers
-    this.clock.runAll()
+    this.clock.next()
     expect(
     expect(
       this.RootDocManager.promises.setRootDocAutomatically
       this.RootDocManager.promises.setRootDocAutomatically
     ).to.have.been.calledWith(this.projects.active1._id)
     ).to.have.been.calledWith(this.projects.active1._id)
@@ -519,7 +519,7 @@ function expectProjectNotCreated() {
 
 
   it('does not set the root doc', function () {
   it('does not set the root doc', function () {
     // Fire pending timers
     // Fire pending timers
-    this.clock.runAll()
+    this.clock.next()
     expect(this.RootDocManager.promises.setRootDocAutomatically).not.to.have
     expect(this.RootDocManager.promises.setRootDocAutomatically).not.to.have
       .been.called
       .been.called
   })
   })