File tree Expand file tree Collapse file tree 1 file changed +8
-2
lines changed
packages/data-service/src Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -23,7 +23,7 @@ import { mochaTestServer } from '@mongodb-js/compass-test-server';
2323import type { SearchIndex } from './search-index-detail-helper' ;
2424import { range } from 'lodash' ;
2525import ConnectionString from 'mongodb-connection-string-url' ;
26- import { DataServiceImplLogger , MongoLogId } from './logger' ;
26+ import type { DataServiceImplLogger , MongoLogId } from './logger' ;
2727
2828const { expect } = chai ;
2929chai . use ( chaiAsPromised ) ;
@@ -164,7 +164,13 @@ describe('DataService', function () {
164164
165165 it ( 'when connecting fails there is a start and failure log with a connectionId' , async function ( ) {
166166 dataServiceLogTest = new DataServiceImpl (
167- { connectionString : 'mongodb://iLoveJavascript' } ,
167+ {
168+ connectionString :
169+ 'mongodb://iLoveJavascript?serverSelectionTimeoutMS=5' ,
170+ lookup : ( ) => {
171+ throw new Error ( 'test error' ) ;
172+ } ,
173+ } ,
168174 logCollector
169175 ) ;
170176
You can’t perform that action at this time.
0 commit comments