aboutsummaryrefslogtreecommitdiffstats
path: root/lib/diameter/test/diameter_tls_SUITE.erl
diff options
context:
space:
mode:
authorErlang/OTP <[email protected]>2015-05-29 12:40:18 +0200
committerErlang/OTP <[email protected]>2015-05-29 12:40:18 +0200
commite7c279de571a1436af5531597d1f8a7a5b6de490 (patch)
tree5d319950adbdddc669571e6f750b00f11a984653 /lib/diameter/test/diameter_tls_SUITE.erl
parent6c179d9c4184ca44e6bff649642f710125906977 (diff)
parentd13288d8116e7780a577d023517b24ae329ac823 (diff)
downloadotp-e7c279de571a1436af5531597d1f8a7a5b6de490.tar.gz
otp-e7c279de571a1436af5531597d1f8a7a5b6de490.tar.bz2
otp-e7c279de571a1436af5531597d1f8a7a5b6de490.zip
Merge branch 'anders/diameter/test/OTP-12767' into maint-17
* anders/diameter/test/OTP-12767: Replace config suite call to erlang:now/0 Fix incorrect suite usage of OTP 18 monotonic time Make tls suite crash more verbosely
Diffstat (limited to 'lib/diameter/test/diameter_tls_SUITE.erl')
-rw-r--r--lib/diameter/test/diameter_tls_SUITE.erl18
1 files changed, 9 insertions, 9 deletions
diff --git a/lib/diameter/test/diameter_tls_SUITE.erl b/lib/diameter/test/diameter_tls_SUITE.erl
index 55565692ec..e5bbda9c91 100644
--- a/lib/diameter/test/diameter_tls_SUITE.erl
+++ b/lib/diameter/test/diameter_tls_SUITE.erl
@@ -319,19 +319,19 @@ make_cert(Dir, Base) ->
make_cert(Dir, Base ++ "_key.pem", Base ++ "_ca.pem").
make_cert(Dir, Keyfile, Certfile) ->
- [K,C] = Paths = [filename:join([Dir, F]) || F <- [Keyfile, Certfile]],
+ [KP,CP] = [filename:join([Dir, F]) || F <- [Keyfile, Certfile]],
- KCmd = join(["openssl genrsa -out", K, "2048"]),
- CCmd = join(["openssl req -new -x509 -key", K, "-out", C, "-days 7",
- "-subj /C=SE/ST=./L=Stockholm/CN=www.erlang.org"]),
+ KC = join(["openssl genrsa -out", KP, "2048"]),
+ CC = join(["openssl req -new -x509 -key", KP, "-out", CP, "-days 7",
+ "-subj /C=SE/ST=./L=Stockholm/CN=www.erlang.org"]),
%% Hope for the best and only check that files are written.
- os:cmd(KCmd),
- os:cmd(CCmd),
+ [{_, _, {ok,_}},{_, _, {ok,_}}]
+ = [{P,O,T} || {P,C} <- [{KP,KC}, {CP,CC}],
+ O <- [os:cmd(C)],
+ T <- [file:read_file_info(P)]],
- [_,_] = [T || P <- Paths, {ok, T} <- [file:read_file_info(P)]],
-
- {K,C}.
+ {KP,CP}.
join(Strs) ->
string:join(Strs, " ").