Sha256: 2697ea05434be119525dfa308b3de692c1c7ea38d2c1e6cbca55091c2ec17169

Contents?: true

Size: 1.18 KB

Versions: 6

Compression:

Stored size: 1.18 KB

Contents

require File.dirname(__FILE__) + '/../spec_helper'

include PoolParty::Resources
require File.dirname(__FILE__) + '/test_plugins/webserver'

describe "Plugin" do
  describe "wrapped" do
    before(:each) do
      reset!
      cloud :app_for_plugin do
        apachetest do
          enable_php
          site("heady", {
            :document_root => "/root"
          })
        end
        apachetest do
          site("boob")
        end
      end
      @plugin = clouds[:app_for_plugin].apachetest
    end
    it "should not be empty" do
      clouds[:app_for_plugin].apachetest.class.should == ApachetestClass
    end
    it "should set loaded == true" do
      clouds[:app_for_plugin].apachetest.loaded.should == true
    end
    it "should have enable_php as a method" do
      ApachetestClass.new.respond_to?(:enable_php).should == true
    end
    it "should set enable_php" do
      @plugin.enable_php.should == true
    end
    it "should store the plugin in the clouds plugin_store" do
      clouds[:app_for_plugin].plugin_store[0].class.should == @plugin.class
      clouds[:app_for_plugin].apachetest
      clouds[:app_for_plugin].plugin_store[0].class.should == @plugin.class
    end
  end
end

Version data entries

6 entries across 6 versions & 2 rubygems

Version Path
auser-poolparty-1.1.1 spec/poolparty/poolparty/plugin_spec.rb
auser-poolparty-1.1.3 spec/poolparty/poolparty/plugin_spec.rb
auser-poolparty-1.1.4 spec/poolparty/poolparty/plugin_spec.rb
auser-poolparty-1.1.5 spec/poolparty/poolparty/plugin_spec.rb
fairchild-poolparty-1.1.3 spec/poolparty/poolparty/plugin_spec.rb
fairchild-poolparty-1.1.4 spec/poolparty/poolparty/plugin_spec.rb