Skip to content

Commit

Permalink
Fixed rspec tests to follow new syntax layout
Browse files Browse the repository at this point in the history
Resolved issues with spec tests failing as the file layout changed with
new lines, causing errors in the tests. I have updated the ssl_options
sections to ensure the changes are reflected in testing.
  • Loading branch information
danielgadd committed Feb 22, 2015
1 parent 5d0a9ff commit 74accfc
Showing 1 changed file with 10 additions and 5 deletions.
15 changes: 10 additions & 5 deletions spec/classes/rabbitmq_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -483,7 +483,10 @@
%r{ssl_listeners, \[3141\]}
)
should contain_file('rabbitmq.config').with_content(
%r{ssl_options, \[\{cacertfile,"/path/to/cacert"}
%r{ssl_options, \[}
)
should contain_file('rabbitmq.config').with_content(
%r{cacertfile,"/path/to/cacert"}
)
should contain_file('rabbitmq.config').with_content(
%r{certfile,"/path/to/cert"}
Expand All @@ -507,7 +510,7 @@

it 'should set ssl options to specified values' do
should contain_file('rabbitmq.config').with_content(%r{ssl_listeners, \[\{"0.0.0.0", 3141\}\]})
should contain_file('rabbitmq.config').with_content(%r{ssl_options, \[\{cacertfile,"/path/to/cacert"})
should contain_file('rabbitmq.config').with_content(%r{cacertfile,"/path/to/cacert"})
should contain_file('rabbitmq.config').with_content(%r{certfile,"/path/to/cert"})
should contain_file('rabbitmq.config').with_content(%r{keyfile,"/path/to/key})
end
Expand All @@ -528,7 +531,8 @@
it 'should set ssl options to specified values' do
should contain_file('rabbitmq.config').with_content(%r{tcp_listeners, \[\]})
should contain_file('rabbitmq.config').with_content(%r{ssl_listeners, \[3141\]})
should contain_file('rabbitmq.config').with_content(%r{ssl_options, \[\{cacertfile,"/path/to/cacert"})
should contain_file('rabbitmq.config').with_content(%r{ssl_options, \[})
should contain_file('rabbitmq.config').with_content(%r{cacertfile,"/path/to/cacert"})
should contain_file('rabbitmq.config').with_content(%r{certfile,"/path/to/cert"})
should contain_file('rabbitmq.config').with_content(%r{keyfile,"/path/to/key})
end
Expand All @@ -548,7 +552,7 @@
it 'should set ssl options to specified values' do
should contain_file('rabbitmq.config').with_content(%r{tcp_listeners, \[\]})
should contain_file('rabbitmq.config').with_content(%r{ssl_listeners, \[\{"0.0.0.0", 3141\}\]})
should contain_file('rabbitmq.config').with_content(%r{ssl_options, \[\{cacertfile,"/path/to/cacert"})
should contain_file('rabbitmq.config').with_content(%r{cacertfile,"/path/to/cacert"})
should contain_file('rabbitmq.config').with_content(%r{certfile,"/path/to/cert"})
should contain_file('rabbitmq.config').with_content(%r{keyfile,"/path/to/key})
end
Expand All @@ -566,7 +570,8 @@

it 'should set ssl options to specified values' do
should contain_file('rabbitmq.config').with_content(%r{ssl_listeners, \[3141\]})
should contain_file('rabbitmq.config').with_content(%r{ssl_options, \[\{cacertfile,"/path/to/cacert"})
should contain_file('rabbitmq.config').with_content(%r{ssl_options, \[})
should contain_file('rabbitmq.config').with_content(%r{cacertfile,"/path/to/cacert"})
should contain_file('rabbitmq.config').with_content(%r{certfile,"/path/to/cert"})
should contain_file('rabbitmq.config').with_content(%r{keyfile,"/path/to/key})
should contain_file('rabbitmq.config').with_content(%r{ssl, \[\{versions, \['tlsv1.1', 'tlsv1.2'\]\}\]})
Expand Down

0 comments on commit 74accfc

Please sign in to comment.