tests/multi_net: Require SSL cert file to be available for test to run.

These were missed in 2bba507148 because they
didn't use the `os.stat` pattern.

Signed-off-by: Damien George <damien@micropython.org>
This commit is contained in:
Damien George
2025-08-27 13:31:18 +10:00
parent af745a5982
commit 3274f0355b
4 changed files with 16 additions and 32 deletions

View File

@@ -14,14 +14,10 @@ PORT = 8000
certfile = "ec_cert.der"
keyfile = "ec_key.der"
try:
with open(certfile, "rb") as cf:
cert = cadata = cf.read()
with open(keyfile, "rb") as kf:
key = kf.read()
except OSError:
print("SKIP")
raise SystemExit
with open(certfile, "rb") as cf:
cert = cadata = cf.read()
with open(keyfile, "rb") as kf:
key = kf.read()
# Server

View File

@@ -14,14 +14,10 @@ PORT = 8000
cert = cafile = "ec_cert.der"
key = "ec_key.der"
try:
with open(cafile, "rb") as f:
cadata = f.read()
with open(key, "rb") as f:
keydata = f.read()
except OSError:
print("SKIP")
raise SystemExit
with open(cafile, "rb") as f:
cadata = f.read()
with open(key, "rb") as f:
keydata = f.read()
# Server

View File

@@ -15,14 +15,10 @@ PORT = 8000
cert = cafile = "ec_cert.der"
key = "ec_key.der"
try:
with open(cafile, "rb") as f:
cadata = f.read()
with open(key, "rb") as f:
key = f.read()
except OSError:
print("SKIP")
raise SystemExit
with open(cafile, "rb") as f:
cadata = f.read()
with open(key, "rb") as f:
key = f.read()
def verify_callback(cert, depth):

View File

@@ -13,14 +13,10 @@ PORT = 8000
certfile = "ec_cert.der"
keyfile = "ec_key.der"
try:
with open(certfile, "rb") as cf:
cert = cadata = cf.read()
with open(keyfile, "rb") as kf:
key = kf.read()
except OSError:
print("SKIP")
raise SystemExit
with open(certfile, "rb") as cf:
cert = cadata = cf.read()
with open(keyfile, "rb") as kf:
key = kf.read()
# DTLS server.