summaryrefslogtreecommitdiff
path: root/puppet/modules/haproxy/spec/defines/listen_spec.rb
diff options
context:
space:
mode:
authorMicah Anderson <micah@riseup.net>2017-11-28 11:35:01 -0500
committerMicah Anderson <micah@riseup.net>2017-11-28 11:35:01 -0500
commit0d251e2ceddd3e02ed8bba8725830689dbdd1397 (patch)
tree37d7096d9e458ca1e6431dff8a2f571553011c44 /puppet/modules/haproxy/spec/defines/listen_spec.rb
parent93a181d44e2d8163ae44945aac1b6477e268170d (diff)
parentbf6c56d86c7ba45e7ca766d990a9e9162025e5ac (diff)
Merge tag 'refs/tags/0.10.0' into stable
Release 0.10.0
Diffstat (limited to 'puppet/modules/haproxy/spec/defines/listen_spec.rb')
-rw-r--r--puppet/modules/haproxy/spec/defines/listen_spec.rb53
1 files changed, 0 insertions, 53 deletions
diff --git a/puppet/modules/haproxy/spec/defines/listen_spec.rb b/puppet/modules/haproxy/spec/defines/listen_spec.rb
deleted file mode 100644
index 31dd4c85..00000000
--- a/puppet/modules/haproxy/spec/defines/listen_spec.rb
+++ /dev/null
@@ -1,53 +0,0 @@
-require 'spec_helper'
-
-describe 'haproxy::listen' do
- let(:title) { 'tyler' }
- let(:facts) {{ :ipaddress => '1.1.1.1' }}
- context "when only one port is provided" do
- let(:params) do
- {
- :name => 'croy',
- :ports => '18140'
- }
- end
-
- it { should contain_concat__fragment('croy_listen_block').with(
- 'order' => '20-croy-00',
- 'target' => '/etc/haproxy/haproxy.cfg',
- 'content' => "listen croy\n\n bind 1.1.1.1:18140\n\n balance roundrobin\n option tcplog\n option ssl-hello-chk\n"
- ) }
- end
- context "when an array of ports is provided" do
- let(:params) do
- {
- :name => 'apache',
- :ipaddress => '23.23.23.23',
- :ports => [
- '80',
- '443',
- ]
- }
- end
-
- it { should contain_concat__fragment('apache_listen_block').with(
- 'order' => '20-apache-00',
- 'target' => '/etc/haproxy/haproxy.cfg',
- 'content' => "listen apache\n\n bind 23.23.23.23:80\n\n bind 23.23.23.23:443\n\n balance roundrobin\n option tcplog\n option ssl-hello-chk\n"
- ) }
- end
- context "when a comma-separated list of ports is provided" do
- let(:params) do
- {
- :name => 'apache',
- :ipaddress => '23.23.23.23',
- :ports => '80,443'
- }
- end
-
- it { should contain_concat__fragment('apache_listen_block').with(
- 'order' => '20-apache-00',
- 'target' => '/etc/haproxy/haproxy.cfg',
- 'content' => "listen apache\n\n bind 23.23.23.23:80\n\n bind 23.23.23.23:443\n\n balance roundrobin\n option tcplog\n option ssl-hello-chk\n"
- ) }
- end
-end