From 657f064e3513bb3a7b41284dee8b120a83626dfc Mon Sep 17 00:00:00 2001 From: Maciej Szlosarczyk Date: Tue, 28 May 2019 09:58:11 +0300 Subject: [PATCH] Use standard erlang folder structure --- {fixtures => apps/epp_proxy/priv}/epp-proxy-test.crt.pem | 0 {fixtures => apps/epp_proxy/priv}/epp-proxy-test.key.pem | 0 apps/epp_proxy/src/epp_proxy.app.src | 4 ++-- apps/epp_proxy/test/epp_certs_tests.erl | 3 ++- config/test.config | 8 ++++---- 5 files changed, 8 insertions(+), 7 deletions(-) rename {fixtures => apps/epp_proxy/priv}/epp-proxy-test.crt.pem (100%) rename {fixtures => apps/epp_proxy/priv}/epp-proxy-test.key.pem (100%) diff --git a/fixtures/epp-proxy-test.crt.pem b/apps/epp_proxy/priv/epp-proxy-test.crt.pem similarity index 100% rename from fixtures/epp-proxy-test.crt.pem rename to apps/epp_proxy/priv/epp-proxy-test.crt.pem diff --git a/fixtures/epp-proxy-test.key.pem b/apps/epp_proxy/priv/epp-proxy-test.key.pem similarity index 100% rename from fixtures/epp-proxy-test.key.pem rename to apps/epp_proxy/priv/epp-proxy-test.key.pem diff --git a/apps/epp_proxy/src/epp_proxy.app.src b/apps/epp_proxy/src/epp_proxy.app.src index 566fab7..e448b28 100644 --- a/apps/epp_proxy/src/epp_proxy.app.src +++ b/apps/epp_proxy/src/epp_proxy.app.src @@ -5,8 +5,8 @@ {mod, {epp_proxy_app, []}}, {applications, [kernel, - stdlib - ]}, + stdlib, + ssl]}, {env,[]}, {modules, []}, diff --git a/apps/epp_proxy/test/epp_certs_tests.erl b/apps/epp_proxy/test/epp_certs_tests.erl index 2a3eefd..8057964 100644 --- a/apps/epp_proxy/test/epp_certs_tests.erl +++ b/apps/epp_proxy/test/epp_certs_tests.erl @@ -3,7 +3,8 @@ -include_lib("eunit/include/eunit.hrl"). -include_lib("public_key/include/public_key.hrl"). --define(exampleCertFile, "fixtures/epp-proxy-test.crt.pem"). +-define(exampleCertFile, lists:flatten([code:lib_dir(epp_proxy, priv), + "epp-proxy-test.crt.pem"])). wder_certificate_test() -> PemEntries = public_key:pem_decode(certificate_pem()), diff --git a/config/test.config b/config/test.config index 90e781d..7274b21 100644 --- a/config/test.config +++ b/config/test.config @@ -1,9 +1,9 @@ [ - {epp_proxy, [{tcp_port, 17001, - {tls_port, 17002}, + {epp_proxy, [{tcp_port, 3333}, + {tls_port, 4444}, {epp_session_url, "https://registry.test/epp/session/"}, {epp_command_url, "https://registry.test/epp/command/"}, {cacertfile_path, "/opt/shared/ca/certs/ca.crt.pem"}, - {certfile_path, "/opt/shared/ca/certs/ca.crt.pem"}, - {keyfile_path, "/opt/shared/ca/certs/ca.crt.pem"}]} + {certfile_path, "/opt/shared/ca/certs/apache.crt"}, + {keyfile_path, "/opt/shared/ca/private/apache.key"}]} ].