Fix rest of notebook unhandled promises (#16933)

* Fix rest of notebook unhandled promises

* add rule

* fix some tests
This commit is contained in:
Charles Gagnon
2021-08-30 14:14:48 -07:00
committed by GitHub
parent 26e08fdf9e
commit 76e01fee60
21 changed files with 79 additions and 53 deletions

View File

@@ -65,7 +65,7 @@ describe('Jupyter Session Manager', function (): void {
sessionManager.ready.then(() => {
should(sessionManager.isReady).be.true();
done();
});
}).catch(err => done(err));
});
it('should passthrough the ready calls', function (done): void {
@@ -75,7 +75,7 @@ describe('Jupyter Session Manager', function (): void {
// When I wait on the ready method before completing
sessionManager.setJupyterSessionManager(mockJupyterManager.object);
sessionManager.ready.then(() => done());
sessionManager.ready.then(() => done()).catch(err => done(err));
// Then session manager should eventually resolve
deferred.resolve();