@@ -120,7 +120,7 @@ describe('Server Operation Count Tests', function () {
120
120
it ( 'is zero after a successful command' , testMetadata , async function ( ) {
121
121
const server = Array . from ( client . topology . s . servers . values ( ) ) [ 0 ] ;
122
122
expect ( server . s . operationCount ) . to . equal ( 0 ) ;
123
- const commandSpy = sinon . spy ( server , 'command ' ) ;
123
+ const commandSpy = sinon . spy ( server , 'modernCommand ' ) ;
124
124
const incrementSpy = sinon . spy ( server , 'incrementOperationCount' ) ;
125
125
const decrementSpy = sinon . spy ( server , 'decrementOperationCount' ) ;
126
126
@@ -147,7 +147,7 @@ describe('Server Operation Count Tests', function () {
147
147
const server = Array . from ( client . topology . s . servers . values ( ) ) [ 0 ] ;
148
148
expect ( server . s . operationCount ) . to . equal ( 0 ) ;
149
149
150
- const commandSpy = sinon . spy ( server , 'command ' ) ;
150
+ const commandSpy = sinon . spy ( server , 'modernCommand ' ) ;
151
151
152
152
const error = await collection . insertOne ( { count : 1 } ) . catch ( e => e ) ;
153
153
@@ -171,7 +171,7 @@ describe('Server Operation Count Tests', function () {
171
171
sinon
172
172
. stub ( ConnectionPool . prototype , 'checkOut' )
173
173
. rejects ( new Error ( 'unable to checkout connection' ) ) ;
174
- const commandSpy = sinon . spy ( server , 'command ' ) ;
174
+ const commandSpy = sinon . spy ( server , 'modernCommand ' ) ;
175
175
176
176
const error = await collection . insertOne ( { count : 1 } ) . catch ( e => e ) ;
177
177
0 commit comments