Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Fixed startup applications (per Joe's suggestion) and made the cert f…

…iles local to the test instead of hard-coded paths.
  • Loading branch information...
commit fd35afaf8a701cfb4abddf60c247ee943438e372 1 parent f4bff7c
Jeffrey Massung massung authored
Showing with 46 additions and 11 deletions.
  1. +17 −0 test/cert.pem
  2. +14 −11 test/eqc_routes.erl
  3. +15 −0 test/key.pem
17 test/cert.pem
View
@@ -0,0 +1,17 @@
+-----BEGIN CERTIFICATE-----
+MIICvTCCAiYCCQDgxT3HogRJ/TANBgkqhkiG9w0BAQUFADCBojELMAkGA1UEBhMC
+VVMxFjAUBgNVBAgTDU1hc3NhY2h1c2V0dHMxEjAQBgNVBAcTCUNhbWJyaWRnZTEf
+MB0GA1UEChMWQmFzaG8gVGVjaG5vbG9naWVzIEluYzENMAsGA1UECxMEUmlhazEY
+MBYGA1UEAxMPSmVmZnJleSBNYXNzdW5nMR0wGwYJKoZIhvcNAQkBFg5qZWZmQGJh
+c2hvLmNvbTAeFw0xMTEwMzExNjQ3NTNaFw0yMTEwMjgxNjQ3NTNaMIGiMQswCQYD
+VQQGEwJVUzEWMBQGA1UECBMNTWFzc2FjaHVzZXR0czESMBAGA1UEBxMJQ2FtYnJp
+ZGdlMR8wHQYDVQQKExZCYXNobyBUZWNobm9sb2dpZXMgSW5jMQ0wCwYDVQQLEwRS
+aWFrMRgwFgYDVQQDEw9KZWZmcmV5IE1hc3N1bmcxHTAbBgkqhkiG9w0BCQEWDmpl
+ZmZAYmFzaG8uY29tMIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQCkys/CB8Ce
+fO19JsFiL2K5pODMWFmXxfQgvARB2rIvoJ4R4mNKI639xRbR+gCPreJvZRw8trgD
+8sARFv8J1SlqqYRDN8zfMlvolXh6Atujou/LwjUpTA3pMe9lZrWU1+JZOMAk79lz
+O/1etfR12By0SqNfDgUMIIZST7i3Fw2IkwIDAQABMA0GCSqGSIb3DQEBBQUAA4GB
+ABTOXMBYoEn0biwqaDcZzInZvZHupFkmkOABumgJ5xVDQ/9LIzy9mfg0Ko+JERlM
+0w0dliu2sfFoXLps9EohjIzrU1B3CwSNvNqPmcj9V4k0iXrsvDfbG9eJ9nYaUY0Y
+L5I9/KAOIf3fEmnFbjtmyiLVhrM6kBB3fvoAVQfwL6cZ
+-----END CERTIFICATE-----
25 test/eqc_routes.erl
View
@@ -29,15 +29,12 @@ prop_routes () ->
begin
setup(Auth),
- %% start applications
- [application:start(App) || App <- [sasl,
- crypto,
- inets,
- riak_sysmon,
- webmachine,
- os_mon,
- riak_core,
- riak_control]],
+ %% start application dependencies
+ riak_core_util:start_app_deps(riak_core),
+ riak_core_util:start_app_deps(riak_control),
+
+ %% can now start riak control
+ application:start(riak_control),
%% ensure riak_control is up and running
riak_core:wait_for_application(riak_control),
@@ -194,11 +191,17 @@ setup (Auth) ->
%% hide sasl output
application:set_env(sasl,sasl_error_logger,false),
+ %% local the pem files in the test folder
+ PrivDir=code:priv_dir(riak_control),
+ TestDir=filename:join([PrivDir,"..","test"]),
+ CertFile=filename:join([TestDir,"cert.pem"]),
+ KeyFile=filename:join([TestDir,"key.pem"]),
+
%% set env values for riak core
set(http, [{"127.0.0.1",18098}]),
set(https, [{"127.0.0.1",18069}]),
- set(ssl, [{certfile, "/Users/jeff/Projects/b/riak/rel/files/cert.pem"},
- {keyfile, "/Users/jeff/Projects/b/riak/rel/files/key.pem"}
+ set(ssl, [{certfile, CertFile},
+ {keyfile, KeyFile}
]),
%% finally, enable riak control
15 test/key.pem
View
@@ -0,0 +1,15 @@
+-----BEGIN RSA PRIVATE KEY-----
+MIICXAIBAAKBgQCkys/CB8CefO19JsFiL2K5pODMWFmXxfQgvARB2rIvoJ4R4mNK
+I639xRbR+gCPreJvZRw8trgD8sARFv8J1SlqqYRDN8zfMlvolXh6Atujou/LwjUp
+TA3pMe9lZrWU1+JZOMAk79lzO/1etfR12By0SqNfDgUMIIZST7i3Fw2IkwIDAQAB
+AoGANAW2eolZ/G5xxo2ChQ1yfCqZsMi/V9NtExxnt6Zjk/d/jyPJtnD3D2K1ponm
+vXTmQ8ZGmMAR7WUnzv1Ue/UoAntcyXwKAm+T+2IUJiir/qzYKLSn8FJ3wA+OWYKs
+1nSryi54IuNenKUslxMPDPk/0bM6nZS2AvbNPYhX7a8evXkCQQDNdsvDO3Ofn0pJ
++3bMLH5Ch/adrJ0TfF1H8n9pxiuq813ppffXsyzv3haTbGHOtEM5tILYbHmO16h1
+vY+hhoHHAkEAzVMVRaDefjp1qKfoyRm9ySa3GgH71t1dvm1jGTRxNk9M8pekLDz+
+GWyTzffM2/+8Xz4RFzLjqAoAjzBGMeAC1QJAANiycjV2fnvbhH6CuMieJIwG2hNx
++jiS8c7v83GbkHK8OlAyuzLDxqE1mpnhtUZM2JoDx/x6a7o7uXB0fQfe1QJBAKxi
+d/aYhJS4IjaymqfUm9m5TntgdP9FpcIOdugfdnmhhLochLK7lp7j4QhJZ07B3Hae
+Vp0Clc5sb2HIpvaS2+0CQEV5NxPjavmlCQksQvU2OAQvTW3Sm9lahTl4XvdVxfj0
+G9sZ2erg7MIo2LF4V6FM6Hbfoj/FhAMOXlXUoUGs1uI=
+-----END RSA PRIVATE KEY-----
Please sign in to comment.
Something went wrong with that request. Please try again.