Remove redundant code to reload tls cert (#10054)

we don't need to reload the tls cert if we don't have any tls listeners.

Follow-up to #9280.
This commit is contained in:
Richard van der Hoff 2021-05-27 10:34:24 +01:00 committed by GitHub
parent 224f2f949b
commit fe5dad46b0
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 6 additions and 25 deletions

View file

@ -74,12 +74,11 @@ s4niecZKPBizL6aucT59CsunNmmb5Glq8rlAcU+1ZTZZzGYqVYhF6axB9Qg=
config = {
"tls_certificate_path": os.path.join(config_dir, "cert.pem"),
"tls_fingerprints": [],
}
t = TestConfig()
t.read_config(config, config_dir_path="", data_dir_path="")
t.read_certificate_from_disk(require_cert_and_key=False)
t.read_tls_certificate()
warnings = self.flushWarnings()
self.assertEqual(len(warnings), 1)