@@ -77,19 +77,17 @@ describe('TLS Support', function () {
7777
7878 it ( 'sets the default options' , async function ( ) {
7979 await client . connect ( ) ;
80- expect ( tlsSpy ) . to . have . been . calledWith ( {
81- autoSelectFamily : true ,
82- host : 'localhost' ,
83- port : 27017 ,
84- servername : 'localhost' ,
85- ca : sinon . match . defined ,
86- cert : sinon . match . defined ,
87- key : sinon . match . defined
88- } ) ;
80+ expect ( tlsSpy ) . to . have . been . calledWith (
81+ sinon . match ( {
82+ ca : sinon . match . defined ,
83+ cert : sinon . match . defined ,
84+ key : sinon . match . defined
85+ } )
86+ ) ;
8987 } ) ;
9088 } ) ;
9189
92- context ( 'when auto family options are set' , function ( ) {
90+ context ( 'when auto select family options are set' , function ( ) {
9391 let tlsSpy ;
9492
9593 afterEach ( function ( ) {
@@ -107,16 +105,15 @@ describe('TLS Support', function () {
107105
108106 it ( 'sets the provided options' , async function ( ) {
109107 await client . connect ( ) ;
110- expect ( tlsSpy ) . to . have . been . calledWith ( {
111- autoSelectFamily : false ,
112- autoSelectFamilyAttemptTimeout : 100 ,
113- host : 'localhost' ,
114- port : 27017 ,
115- servername : 'localhost' ,
116- ca : sinon . match . defined ,
117- cert : sinon . match . defined ,
118- key : sinon . match . defined
119- } ) ;
108+ expect ( tlsSpy ) . to . have . been . calledWith (
109+ sinon . match ( {
110+ autoSelectFamily : false ,
111+ autoSelectFamilyAttemptTimeout : 100 ,
112+ ca : sinon . match . defined ,
113+ cert : sinon . match . defined ,
114+ key : sinon . match . defined
115+ } )
116+ ) ;
120117 } ) ;
121118 } ) ;
122119
0 commit comments