File tree Expand file tree Collapse file tree 1 file changed +10
-2
lines changed
Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Original file line number Diff line number Diff line change @@ -17,6 +17,7 @@ import {
1717 MongoDBAWS ,
1818 type MongoDBNamespace ,
1919 type MongoDBResponseConstructor ,
20+ MongoError ,
2021 MongoMissingCredentialsError ,
2122 MongoServerError ,
2223 setDifference
@@ -116,10 +117,17 @@ describe('MONGODB-AWS', function () {
116117 sinon . restore ( ) ;
117118 } ) ;
118119
119- it . only ( 'should use conversationId returned by saslStart in saslContinue' , async function ( ) {
120+ it ( 'should use conversationId returned by saslStart in saslContinue' , async function ( ) {
120121 client = this . configuration . newClient ( process . env . MONGODB_URI ) ; // use the URI built by the test environment
121122
122- await client . db ( 'aws' ) . collection ( 'aws_test' ) . estimatedDocumentCount ( ) ;
123+ const err = await client
124+ . db ( 'aws' )
125+ . collection ( 'aws_test' )
126+ . estimatedDocumentCount ( )
127+ . catch ( e => e ) ;
128+
129+ // Expecting the saslContinue to fail since we changed the conversationId
130+ expect ( err ) . to . be . instanceof ( MongoError ) ;
123131
124132 expect ( saslStartResult ) . to . not . be . undefined ;
125133 expect ( saslContinue ) . to . not . be . undefined ;
You can’t perform that action at this time.
0 commit comments