]> git.donarmstrong.com Git - dsa-puppet.git/blobdiff - 3rdparty/modules/apache/spec/classes/mod/fastcgi_spec.rb
try again, with puppetforge modules, correctly included now
[dsa-puppet.git] / 3rdparty / modules / apache / spec / classes / mod / fastcgi_spec.rb
diff --git a/3rdparty/modules/apache/spec/classes/mod/fastcgi_spec.rb b/3rdparty/modules/apache/spec/classes/mod/fastcgi_spec.rb
new file mode 100644 (file)
index 0000000..e204bb7
--- /dev/null
@@ -0,0 +1,45 @@
+require 'spec_helper'
+
+describe 'apache::mod::fastcgi', :type => :class do
+  let :pre_condition do
+    'include apache'
+  end
+  context "on a Debian OS" do
+    let :facts do
+      {
+        :osfamily               => 'Debian',
+        :operatingsystemrelease => '6',
+        :concat_basedir         => '/dne',
+        :lsbdistcodename        => 'squeze',
+        :operatingsystem        => 'Debian',
+        :id                     => 'root',
+        :kernel                 => 'Linux',
+        :path                   => '/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin',
+        :is_pe                  => false,
+      }
+    end
+    it { is_expected.to contain_class("apache::params") }
+    it { is_expected.to contain_apache__mod('fastcgi') }
+    it { is_expected.to contain_package("libapache2-mod-fastcgi") }
+    it { is_expected.to contain_file('fastcgi.conf') }
+  end
+
+  context "on a RedHat OS" do
+    let :facts do
+      {
+        :osfamily               => 'RedHat',
+        :operatingsystemrelease => '6',
+        :concat_basedir         => '/dne',
+        :operatingsystem        => 'RedHat',
+        :id                     => 'root',
+        :kernel                 => 'Linux',
+        :path                   => '/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin',
+        :is_pe                  => false,
+      }
+    end
+    it { is_expected.to contain_class("apache::params") }
+    it { is_expected.to contain_apache__mod('fastcgi') }
+    it { is_expected.to contain_package("mod_fastcgi") }
+    it { is_expected.not_to contain_file('fastcgi.conf') }
+  end
+end