39
39
':/tmp/test_files"'
40
40
)
41
41
42
+
42
43
@pytest .hookimpl ()
43
44
def pytest_sessionfinish (session , exitstatus ):
44
- if os .name == ' posix' :
45
+ if os .name == " posix" :
45
46
# accept ACCEPTABLE_FAILURE_RATE percent of failure on Linux
46
47
if exitstatus != pytest .ExitCode .TESTS_FAILED :
47
48
return
@@ -254,36 +255,36 @@ def server_type_remote_process(request):
254
255
core .settings .get_runtime_client_config (server ).cache_enabled = True
255
256
return server
256
257
257
- @pytest .fixture (scope = "session" , params = [ServerConfig (protocol = CommunicationProtocols .gRPC ,
258
- legacy = True ),
259
- ServerConfig (protocol = CommunicationProtocols .gRPC ,
260
- legacy = False ),
261
- ServerConfig (protocol = CommunicationProtocols .InProcess ,
262
- legacy = False )],
263
- ids = [
264
- "ansys-grpc-dpf config" ,
265
- "gRPC CLayer config" ,
266
- "in Process CLayer config"
267
- ])
258
+ @pytest .fixture (
259
+ scope = "session" ,
260
+ params = [
261
+ ServerConfig (protocol = CommunicationProtocols .gRPC , legacy = True ),
262
+ ServerConfig (protocol = CommunicationProtocols .gRPC , legacy = False ),
263
+ ServerConfig (protocol = CommunicationProtocols .InProcess , legacy = False ),
264
+ ],
265
+ ids = ["ansys-grpc-dpf config" , "gRPC CLayer config" , "in Process CLayer config" ],
266
+ )
268
267
def config_server_type (request ):
269
268
return request .param
270
269
271
- @pytest .fixture (scope = "session" , params = [ ServerConfig ( protocol = CommunicationProtocols . gRPC ,
272
- legacy = True ) ,
273
- ServerConfig ( protocol = CommunicationProtocols . gRPC ,
274
- legacy = False )] ,
275
- ids = [
276
- "ansys-grpc-dpf config" ,
277
- "gRPC CLayer config"
278
- ] )
270
+ @pytest .fixture (
271
+ scope = "session" ,
272
+ params = [
273
+ ServerConfig ( protocol = CommunicationProtocols . gRPC , legacy = True ) ,
274
+ ServerConfig ( protocol = CommunicationProtocols . gRPC , legacy = False ),
275
+ ] ,
276
+ ids = [ "ansys-grpc-dpf config" , "gRPC CLayer config" ],
277
+ )
279
278
def remote_config_server_type (request ):
280
279
return request .param
281
280
282
- @pytest .fixture (scope = "session" , params = [ServerConfig (protocol = CommunicationProtocols .gRPC ,
283
- legacy = True )],
284
- ids = [
285
- "ansys-grpc-dpf" ,
286
- ])
281
+ @pytest .fixture (
282
+ scope = "session" ,
283
+ params = [ServerConfig (protocol = CommunicationProtocols .gRPC , legacy = True )],
284
+ ids = [
285
+ "ansys-grpc-dpf" ,
286
+ ],
287
+ )
287
288
def server_type_legacy_grpc (request ):
288
289
return core .start_local_server (config = request .param , as_global = False )
289
290
@@ -303,19 +304,23 @@ def server_type():
303
304
def server_type_remote_process (request ):
304
305
return core ._global_server ()
305
306
306
- @pytest .fixture (scope = "session" , params = [ServerConfig (protocol = CommunicationProtocols .gRPC ,
307
- legacy = True )],
308
- ids = [
309
- "ansys-grpc-dpf" ,
310
- ])
307
+ @pytest .fixture (
308
+ scope = "session" ,
309
+ params = [ServerConfig (protocol = CommunicationProtocols .gRPC , legacy = True )],
310
+ ids = [
311
+ "ansys-grpc-dpf" ,
312
+ ],
313
+ )
311
314
def config_server_type (request ):
312
315
return request .param
313
316
314
- @pytest .fixture (scope = "session" , params = [ServerConfig (protocol = CommunicationProtocols .gRPC ,
315
- legacy = True )],
316
- ids = [
317
- "ansys-grpc-dpf" ,
318
- ])
317
+ @pytest .fixture (
318
+ scope = "session" ,
319
+ params = [ServerConfig (protocol = CommunicationProtocols .gRPC , legacy = True )],
320
+ ids = [
321
+ "ansys-grpc-dpf" ,
322
+ ],
323
+ )
319
324
def remote_config_server_type (request ):
320
325
return request .param
321
326
0 commit comments