@@ -107,76 +107,76 @@ def test_missing_auth(self):
107107
108108 @with_instrumented_server (auth = False )
109109 def test_admin_connect_with_no_auth (self ):
110- with socketio .SimpleClient () as admin_client :
110+ with socketio .SimpleClient (reconnection = False ) as admin_client :
111111 admin_client .connect ('http://localhost:8900' , namespace = '/admin' )
112- with socketio .SimpleClient () as admin_client :
112+ with socketio .SimpleClient (reconnection = False ) as admin_client :
113113 admin_client .connect ('http://localhost:8900' , namespace = '/admin' ,
114114 auth = {'foo' : 'bar' })
115115
116116 @with_instrumented_server (auth = {'foo' : 'bar' })
117117 def test_admin_connect_with_dict_auth (self ):
118- with socketio .SimpleClient () as admin_client :
118+ with socketio .SimpleClient (reconnection = False ) as admin_client :
119119 admin_client .connect ('http://localhost:8900' , namespace = '/admin' ,
120120 auth = {'foo' : 'bar' })
121- with socketio .SimpleClient () as admin_client :
121+ with socketio .SimpleClient (reconnection = False ) as admin_client :
122122 with pytest .raises (ConnectionError ):
123123 admin_client .connect (
124124 'http://localhost:8900' , namespace = '/admin' ,
125125 auth = {'foo' : 'baz' })
126- with socketio .SimpleClient () as admin_client :
126+ with socketio .SimpleClient (reconnection = False ) as admin_client :
127127 with pytest .raises (ConnectionError ):
128128 admin_client .connect (
129129 'http://localhost:8900' , namespace = '/admin' )
130130
131131 @with_instrumented_server (auth = [{'foo' : 'bar' },
132132 {'u' : 'admin' , 'p' : 'secret' }])
133133 def test_admin_connect_with_list_auth (self ):
134- with socketio .SimpleClient () as admin_client :
134+ with socketio .SimpleClient (reconnection = False ) as admin_client :
135135 admin_client .connect ('http://localhost:8900' , namespace = '/admin' ,
136136 auth = {'foo' : 'bar' })
137- with socketio .SimpleClient () as admin_client :
137+ with socketio .SimpleClient (reconnection = False ) as admin_client :
138138 admin_client .connect ('http://localhost:8900' , namespace = '/admin' ,
139139 auth = {'u' : 'admin' , 'p' : 'secret' })
140- with socketio .SimpleClient () as admin_client :
140+ with socketio .SimpleClient (reconnection = False ) as admin_client :
141141 with pytest .raises (ConnectionError ):
142142 admin_client .connect ('http://localhost:8900' ,
143143 namespace = '/admin' , auth = {'foo' : 'baz' })
144- with socketio .SimpleClient () as admin_client :
144+ with socketio .SimpleClient (reconnection = False ) as admin_client :
145145 with pytest .raises (ConnectionError ):
146146 admin_client .connect ('http://localhost:8900' ,
147147 namespace = '/admin' )
148148
149149 @with_instrumented_server (auth = _custom_auth )
150150 def test_admin_connect_with_function_auth (self ):
151- with socketio .SimpleClient () as admin_client :
151+ with socketio .SimpleClient (reconnection = False ) as admin_client :
152152 admin_client .connect ('http://localhost:8900' , namespace = '/admin' ,
153153 auth = {'foo' : 'bar' })
154- with socketio .SimpleClient () as admin_client :
154+ with socketio .SimpleClient (reconnection = False ) as admin_client :
155155 with pytest .raises (ConnectionError ):
156156 admin_client .connect ('http://localhost:8900' ,
157157 namespace = '/admin' , auth = {'foo' : 'baz' })
158- with socketio .SimpleClient () as admin_client :
158+ with socketio .SimpleClient (reconnection = False ) as admin_client :
159159 with pytest .raises (ConnectionError ):
160160 admin_client .connect ('http://localhost:8900' ,
161161 namespace = '/admin' )
162162
163163 @with_instrumented_server (auth = _async_custom_auth )
164164 def test_admin_connect_with_async_function_auth (self ):
165- with socketio .SimpleClient () as admin_client :
165+ with socketio .SimpleClient (reconnection = False ) as admin_client :
166166 admin_client .connect ('http://localhost:8900' , namespace = '/admin' ,
167167 auth = {'foo' : 'bar' })
168- with socketio .SimpleClient () as admin_client :
168+ with socketio .SimpleClient (reconnection = False ) as admin_client :
169169 with pytest .raises (ConnectionError ):
170170 admin_client .connect ('http://localhost:8900' ,
171171 namespace = '/admin' , auth = {'foo' : 'baz' })
172- with socketio .SimpleClient () as admin_client :
172+ with socketio .SimpleClient (reconnection = False ) as admin_client :
173173 with pytest .raises (ConnectionError ):
174174 admin_client .connect ('http://localhost:8900' ,
175175 namespace = '/admin' )
176176
177177 @with_instrumented_server ()
178178 def test_admin_connect_only_admin (self ):
179- with socketio .SimpleClient () as admin_client :
179+ with socketio .SimpleClient (reconnection = False ) as admin_client :
180180 admin_client .connect ('http://localhost:8900' , namespace = '/admin' )
181181 sid = admin_client .sid
182182 events = self ._expect ({'config' : 1 , 'all_sockets' : 1 ,
@@ -201,10 +201,10 @@ def test_admin_connect_only_admin(self):
201201
202202 @with_instrumented_server ()
203203 def test_admin_connect_with_others (self ):
204- with socketio .SimpleClient () as client1 , \
205- socketio .SimpleClient () as client2 , \
206- socketio .SimpleClient () as client3 , \
207- socketio .SimpleClient () as admin_client :
204+ with socketio .SimpleClient (reconnection = False ) as client1 , \
205+ socketio .SimpleClient (reconnection = False ) as client2 , \
206+ socketio .SimpleClient (reconnection = False ) as client3 , \
207+ socketio .SimpleClient (reconnection = False ) as admin_client :
208208 client1 .connect ('http://localhost:8900' )
209209 client1 .emit ('enter_room' , 'room' )
210210 sid1 = client1 .sid
@@ -251,7 +251,7 @@ def test_admin_connect_with_others(self):
251251
252252 @with_instrumented_server (mode = 'production' , read_only = True )
253253 def test_admin_connect_production (self ):
254- with socketio .SimpleClient () as admin_client :
254+ with socketio .SimpleClient (reconnection = False ) as admin_client :
255255 admin_client .connect ('http://localhost:8900' , namespace = '/admin' )
256256 events = self ._expect ({'config' : 1 , 'server_stats' : 2 },
257257 admin_client )
@@ -272,9 +272,9 @@ def test_admin_connect_production(self):
272272
273273 @with_instrumented_server ()
274274 def test_admin_features (self ):
275- with socketio .SimpleClient () as client1 , \
276- socketio .SimpleClient () as client2 , \
277- socketio .SimpleClient () as admin_client :
275+ with socketio .SimpleClient (reconnection = False ) as client1 , \
276+ socketio .SimpleClient (reconnection = False ) as client2 , \
277+ socketio .SimpleClient (reconnection = False ) as admin_client :
278278 client1 .connect ('http://localhost:8900' )
279279 client2 .connect ('http://localhost:8900' )
280280 admin_client .connect ('http://localhost:8900' , namespace = '/admin' )
0 commit comments