File tree Expand file tree Collapse file tree 1 file changed +5
-6
lines changed Expand file tree Collapse file tree 1 file changed +5
-6
lines changed Original file line number Diff line number Diff line change @@ -88,10 +88,6 @@ describe('MONGODB-AWS', function () {
88
88
options : CommandOptions ,
89
89
responseType ?: MongoDBResponseConstructor
90
90
) {
91
- if ( command . saslStart != null || command . saslContinue != null ) {
92
- console . log ( command ) ;
93
- }
94
-
95
91
const result = await commandStub . wrappedMethod . call (
96
92
this ,
97
93
ns ,
@@ -100,12 +96,14 @@ describe('MONGODB-AWS', function () {
100
96
responseType
101
97
) ;
102
98
103
- if ( command . saslStart != null ) {
104
- // Modify the result to check if the saslContinue uses it
99
+ if ( command . saslStart != null && command . mechanism === 'MONGODB-AWS' ) {
100
+ // Modify the result of the saslStart to check if the saslContinue uses it
105
101
result . conversationId = 999 ;
106
102
saslStartResult = { ...result } ;
107
103
}
104
+
108
105
if ( command . saslContinue != null ) {
106
+ console . log ( 'saving saslContinue' ) ;
109
107
saslContinue = { ...command } ;
110
108
}
111
109
@@ -125,6 +123,7 @@ describe('MONGODB-AWS', function () {
125
123
. collection ( 'aws_test' )
126
124
. estimatedDocumentCount ( )
127
125
. catch ( e => e ) ;
126
+ console . log ( err ) ;
128
127
129
128
// Expecting the saslContinue to fail since we changed the conversationId
130
129
expect ( err ) . to . be . instanceof ( MongoServerError ) ;
You can’t perform that action at this time.
0 commit comments