mirror of
https://github.com/ninenines/cowboy.git
synced 2025-07-14 12:20:24 +00:00
Fix TLS tests for OTP-26+
ct_helper now uses the test certificates generated by public_key. A few adjustments had to be made as a result.
This commit is contained in:
parent
251e70b219
commit
12108ab668
5 changed files with 70 additions and 60 deletions
|
@ -184,22 +184,16 @@ cert(Config) ->
|
|||
ssl -> do_cert(Config)
|
||||
end.
|
||||
|
||||
do_cert(Config0) ->
|
||||
do_cert(Config) ->
|
||||
doc("A client TLS certificate was provided."),
|
||||
{CaCert, Cert, Key} = ct_helper:make_certs(),
|
||||
Config = [{tls_opts, [
|
||||
{cert, Cert},
|
||||
{key, Key},
|
||||
{cacerts, [CaCert]}
|
||||
]}|Config0],
|
||||
Cert = do_get_body("/cert", Config),
|
||||
Cert = do_get_body("/direct/cert", Config),
|
||||
ok.
|
||||
|
||||
cert_undefined(Config) ->
|
||||
doc("No client TLS certificate was provided."),
|
||||
<<"undefined">> = do_get_body("/cert", Config),
|
||||
<<"undefined">> = do_get_body("/direct/cert", Config),
|
||||
<<"undefined">> = do_get_body("/cert", [{no_cert, true}|Config]),
|
||||
<<"undefined">> = do_get_body("/direct/cert", [{no_cert, true}|Config]),
|
||||
ok.
|
||||
|
||||
header(Config) ->
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue