Sha256: f644ec1892093f6eeb8ef297b4045a3b13b0fcbb063a35a9c93995cca1701cdd

Contents?: true

Size: 812 Bytes

Versions: 8

Compression:

Stored size: 812 Bytes

Contents

require "#{File.dirname(__FILE__)}/../../../test_helper"

include_fixture_resources

class ServiceResourceTest < Test::Unit::TestCase
  context "Base" do
    setup do
      PoolParty::Resource.define_resource_methods
      @res = PoolParty::Resources::Service.new "example_service", 
                                                :action => [:enable, :start],
                                                :supports => {:reload => true}
      @base = DependencyResolvers::Chef
      @base.compile_directory = test_dir
    end
    
    should "have the mount method denoted by has_method_name" do

str = <<-EOS
service "example_service" do
  pattern "example_service"
  action :[ :enable, :start ]
  supports :reload => true
end
EOS

      assert_equal str.chomp, @base.compile(@res)
    end
    
  end
  
end

Version data entries

8 entries across 8 versions & 2 rubygems

Version Path
auser-poolparty-1.3.0 test/lib/poolparty/resources/service_test.rb
auser-poolparty-1.3.1 test/lib/poolparty/resources/service_test.rb
auser-poolparty-1.3.2 test/lib/poolparty/resources/service_test.rb
auser-poolparty-1.3.3 test/lib/poolparty/resources/service_test.rb
auser-poolparty-1.3.4 test/lib/poolparty/resources/service_test.rb
poolparty-1.3.4 test/lib/poolparty/resources/service_test.rb
poolparty-1.3.3 test/lib/poolparty/resources/service_test.rb
poolparty-1.3.1 test/lib/poolparty/resources/service_test.rb