@@ -112,6 +112,7 @@ def __init__(self, *args, **kwargs):
112112 extra_script = extra_script ,
113113 EXTRA_CONFIGURE_FLAGS = "-DENABLE_PIC=ON -DENABLE_MONGOC=OFF" ,
114114 SKIP_MOCK_TESTS = "ON" ,
115+ USE_CRYPT_SHARED = "${USE_CRYPT_SHARED}" ,
115116 ** kwargs )
116117 self .add_tags ('client-side-encryption' , 'special' )
117118
@@ -134,10 +135,12 @@ def __init__(self, *args, **kwargs):
134135 CFLAGS = "-fno-omit-frame-pointer" ,
135136 extra_script = extra_script ,
136137 CHECK_LOG = "ON" ,
137- sanitize = ['address' ],
138+ sanitize = [
139+ 'address' ],
138140 EXTRA_CONFIGURE_FLAGS = "-DENABLE_PIC=ON -DENABLE_MONGOC=OFF -DENABLE_EXTRA_ALIGNMENT=OFF" ,
139141 PATH = '/usr/lib/llvm-3.8/bin:$PATH' ,
140142 SKIP_MOCK_TESTS = "ON" ,
143+ USE_CRYPT_SHARED = "${USE_CRYPT_SHARED}" ,
141144 ** kwargs )
142145 self .add_tags ('client-side-encryption' )
143146
@@ -456,19 +459,23 @@ def __init__(self, task_name, suffix_commands, orchestration=True, **kwargs):
456459 ('bucket' , 'mongo-c-toolchain' ),
457460 ('local_file' , 'mongo-c-toolchain.tar.gz' ),
458461 ]))]),
459- shell_mongoc ('sh ./.evergreen/build-and-test-with-toolchain.sh' )
460- ])
462+ shell_mongoc (
463+ 'sh ./.evergreen/build-and-test-with-toolchain.sh' )
464+ ])
461465]
462466
467+
463468class IntegrationTask (MatrixTask ):
464469 axes = OD ([('valgrind' , ['valgrind' , False ]),
465470 ('sanitizer' , ['asan' , 'tsan' , False ]),
466471 ('coverage' , ['coverage' , False ]),
467- ('version' , ['latest' , '6.0' , '5.0' , '4.4' , '4.2' , '4.0' , '3.6' ]),
472+ ('version' , ['latest' , '6.0' , '5.0' ,
473+ '4.4' , '4.2' , '4.0' , '3.6' ]),
468474 ('topology' , ['server' , 'replica_set' , 'sharded_cluster' ]),
469475 ('auth' , [True , False ]),
470476 ('sasl' , ['sasl' , 'sspi' , False ]),
471- ('ssl' , ['openssl' , 'openssl-static' , 'darwinssl' , 'winssl' , False ]),
477+ ('ssl' , ['openssl' , 'openssl-static' ,
478+ 'darwinssl' , 'winssl' , False ]),
472479 ('cse' , [True , False ])])
473480
474481 def __init__ (self , * args , ** kwargs ):
@@ -562,12 +569,12 @@ def to_dict(self):
562569
563570 def _check_allowed (self ):
564571 if self .sanitizer == 'tsan' :
565- require (self .ssl == 'openssl' )
566- prohibit (self .sasl )
567- prohibit (self .valgrind )
568- prohibit (self .coverage )
569- prohibit (self .cse )
570- prohibit (self .version == "3.0" )
572+ require (self .ssl == 'openssl' )
573+ prohibit (self .sasl )
574+ prohibit (self .valgrind )
575+ prohibit (self .coverage )
576+ prohibit (self .cse )
577+ prohibit (self .version == "3.0" )
571578
572579 if self .valgrind :
573580 prohibit (self .cse )
@@ -613,7 +620,8 @@ def _check_allowed(self):
613620 prohibit (self .ssl )
614621
615622 if self .cse :
616- require (self .version == 'latest' or parse_version (self .version ) >= parse_version ("4.2" ))
623+ require (self .version == 'latest' or parse_version (
624+ self .version ) >= parse_version ("4.2" ))
617625 if self .version == 'latest' or parse_version (self .version ) >= parse_version ("6.0" ):
618626 # FLE 2.0 Client-Side Encryption tasks on 6.0 require a non-standalone topology.
619627 require (self .topology in ('server' , 'replica_set' ))
@@ -668,8 +676,9 @@ def to_dict(self):
668676 dns = 'on'
669677 if self .loadbalanced :
670678 dns = 'loadbalanced'
671- commands .append (func ("clone drivers-evergreen-tools" ))
672- commands .append (func ("start load balancer" , MONGODB_URI = "mongodb://localhost:27017,localhost:27018" ))
679+ commands .append (func ("clone drivers-evergreen-tools" ))
680+ commands .append (func (
681+ "start load balancer" , MONGODB_URI = "mongodb://localhost:27017,localhost:27018" ))
673682 elif self .auth :
674683 dns = 'dns-auth'
675684 commands .append (run_tests (SSL = 'ssl' ,
@@ -679,9 +688,9 @@ def to_dict(self):
679688 return task
680689
681690 def _check_allowed (self ):
682- prohibit (self .loadbalanced and self .auth )
691+ prohibit (self .loadbalanced and self .auth )
683692 # Load balancer tests only run on some Linux hosts in Evergreen until CDRIVER-4041 is resolved.
684- prohibit (self .loadbalanced and self .ssl in ["darwinssl" , "winssl" ])
693+ prohibit (self .loadbalanced and self .ssl in ["darwinssl" , "winssl" ])
685694
686695
687696all_tasks = chain (all_tasks , DNSTask .matrix ())
@@ -920,7 +929,8 @@ def name(self):
920929 SSLTask ('openssl-1.0.2' , 'l' ),
921930 SSLTask ('openssl-1.1.0' , 'f' ),
922931 SSLTask ('libressl-2.5' , '.2' , require_tls12 = True ),
923- SSLTask ('libressl-3.0' , '.2' , require_tls12 = True , enable_ssl = "AUTO" , cflags = "-Wno-redundant-decls" ),
932+ SSLTask ('libressl-3.0' , '.2' , require_tls12 = True ,
933+ enable_ssl = "AUTO" , cflags = "-Wno-redundant-decls" ),
924934 SSLTask ('libressl-3.0' , '.2' , require_tls12 = True ),
925935])
926936
@@ -986,7 +996,8 @@ def __init__(self, *args, **kwargs):
986996 self .add_dependency ('debug-compile-aws' )
987997 self .commands .extend ([
988998 func ('fetch build' , BUILD_NAME = self .depends_on ['name' ]),
989- bootstrap (AUTH = "auth" , ORCHESTRATION_FILE = "auth-aws" , VERSION = self .version , TOPOLOGY = "server" ),
999+ bootstrap (AUTH = "auth" , ORCHESTRATION_FILE = "auth-aws" ,
1000+ VERSION = self .version , TOPOLOGY = "server" ),
9901001 func ('run aws tests' , TESTCASE = self .testcase .upper ())])
9911002
9921003 @property
@@ -1030,26 +1041,28 @@ def to_dict(self):
10301041 stapling = 'mustStaple-disableStapling'
10311042
10321043 orchestration_file = '%s-basic-tls-ocsp-%s' % (self .cert , stapling )
1033- orchestration = bootstrap (VERSION = self .version , TOPOLOGY = 'server' , SSL = 'ssl' , OCSP = 'on' , ORCHESTRATION_FILE = orchestration_file )
1044+ orchestration = bootstrap (VERSION = self .version , TOPOLOGY = 'server' ,
1045+ SSL = 'ssl' , OCSP = 'on' , ORCHESTRATION_FILE = orchestration_file )
10341046
10351047 # The cache test expects a revoked response from an OCSP responder, exactly like TEST_4.
10361048 test_column = 'TEST_4' if self .test == 'cache' else self .test .upper ()
10371049
10381050 commands .append (shell_mongoc (
10391051 'TEST_COLUMN=%s CERT_TYPE=%s USE_DELEGATE=%s sh .evergreen/run-ocsp-responder.sh' % (
1040- test_column , self .cert , 'on' if self .delegate == 'delegate' else 'off' )))
1052+ test_column , self .cert , 'on' if self .delegate == 'delegate' else 'off' )))
10411053 commands .append (orchestration )
10421054 if self .depends_on ['name' ] == 'debug-compile-nosasl-openssl-1.0.1' :
10431055 # LD_LIBRARY_PATH is needed so the in-tree OpenSSL 1.0.1 is found at runtime
10441056 if self .test == 'cache' :
10451057 commands .append (shell_mongoc ('export LD_LIBRARY_PATH=$(pwd)/install-dir/lib\n '
1046- 'CERT_TYPE=%s .evergreen/run-ocsp-cache-test.sh' % self .cert ))
1058+ 'CERT_TYPE=%s .evergreen/run-ocsp-cache-test.sh' % self .cert ))
10471059 else :
10481060 commands .append (shell_mongoc ('export LD_LIBRARY_PATH=$(pwd)/install-dir/lib\n '
1049- 'TEST_COLUMN=%s CERT_TYPE=%s sh .evergreen/run-ocsp-test.sh' % (self .test .upper (), self .cert )))
1061+ 'TEST_COLUMN=%s CERT_TYPE=%s sh .evergreen/run-ocsp-test.sh' % (self .test .upper (), self .cert )))
10501062 else :
10511063 if self .test == 'cache' :
1052- commands .append (shell_mongoc ('CERT_TYPE=%s .evergreen/run-ocsp-cache-test.sh' % self .cert ))
1064+ commands .append (shell_mongoc (
1065+ 'CERT_TYPE=%s .evergreen/run-ocsp-cache-test.sh' % self .cert ))
10531066 else :
10541067 commands .append (shell_mongoc (
10551068 'TEST_COLUMN=%s CERT_TYPE=%s sh .evergreen/run-ocsp-test.sh' % (self .test .upper (), self .cert )))
@@ -1076,26 +1089,30 @@ def _check_allowed(self):
10761089
10771090all_tasks = chain (all_tasks , OCSPTask .matrix ())
10781091
1092+
10791093class LoadBalancedTask (MatrixTask ):
10801094 axes = OD ([
10811095 ('asan' , [True ]),
1082- ('build_ssl' , ['openssl' ]), # The SSL library the C driver is built with.
1083- ('test_ssl' , [True , False ]), # Whether tests are run with SSL connections.
1096+ # The SSL library the C driver is built with.
1097+ ('build_ssl' , ['openssl' ]),
1098+ # Whether tests are run with SSL connections.
1099+ ('test_ssl' , [True , False ]),
10841100 ('test_auth' , [True , False ]),
10851101 ('version' , ['5.0' , 'latest' ])
10861102 ])
10871103
1088- def _check_allowed (self ):
1104+ def _check_allowed (self ):
10891105 # Test with both SSL and auth, or neither.
1090- prohibit (self .test_ssl != self .test_auth )
1106+ prohibit (self .test_ssl != self .test_auth )
10911107
10921108 def __init__ (self , * args , ** kwargs ):
10931109 super (LoadBalancedTask , self ).__init__ (* args , ** kwargs )
10941110 if self .asan and self .build_ssl == "openssl" :
1095- self .add_dependency ('debug-compile-asan-clang-openssl' )
1111+ self .add_dependency ('debug-compile-asan-clang-openssl' )
10961112 self .add_tags ('test-asan' )
10971113 else :
1098- raise RuntimeError ("unimplemented configuration for LoadBalancedTask" )
1114+ raise RuntimeError (
1115+ "unimplemented configuration for LoadBalancedTask" )
10991116
11001117 self .add_tags (self .version )
11011118 self .options ['exec_timeout_secs' ] = 3600
@@ -1125,22 +1142,22 @@ def to_dict(self):
11251142 commands .append (
11261143 func ('fetch build' , BUILD_NAME = self .depends_on ['name' ]))
11271144
1128-
11291145 orchestration = bootstrap (TOPOLOGY = 'sharded_cluster' ,
11301146 AUTH = 'auth' if self .test_auth else 'noauth' ,
11311147 SSL = 'ssl' if self .test_ssl else 'nossl' ,
11321148 VERSION = self .version )
11331149 commands .append (orchestration )
1134- commands .append (func ("clone drivers-evergreen-tools" ))
1135- commands .append (func ("start load balancer" ,
1136- MONGODB_URI = "mongodb://localhost:27017,localhost:27018" ))
1150+ commands .append (func ("clone drivers-evergreen-tools" ))
1151+ commands .append (func ("start load balancer" ,
1152+ MONGODB_URI = "mongodb://localhost:27017,localhost:27018" ))
11371153 commands .append (run_tests (ASAN = 'on' if self .asan else 'off' ,
11381154 SSL = 'ssl' if self .test_ssl else 'nossl' ,
11391155 AUTH = 'auth' if self .test_auth else 'noauth' ,
11401156 LOADBALANCED = 'loadbalanced' ))
11411157
11421158 return task
11431159
1160+
11441161all_tasks = chain (all_tasks , LoadBalancedTask .matrix ())
11451162
11461163all_tasks = list (all_tasks )
0 commit comments