Sha256: 02b4141a82e91a9cc7228aed30cd90320f3ec7454479780b8f3ae71e5895c2f6

Contents?: true

Size: 1.03 KB

Versions: 2

Compression:

Stored size: 1.03 KB

Contents

require 'jruby'
require 'torquebox/container/foundation'

describe TorqueBox::Container::Foundation do

  it "should be instantiable" do
    container = TorqueBox::Container::Foundation.new
  end

  it "should be startable and stoppable" do
    container = TorqueBox::Container::Foundation.new
    container.start
    container.stop
  end

  describe "foundational deployment" do
    before(:each) do
      @container = TorqueBox::Container::Foundation.new
      @container.start
    end
    after(:each) do
      @container.stop
    end

    it "should deploy a RuntimePoolDeployer" do
      @container['RuntimePoolDeployer'].should_not be_nil
    end

    it "should expose the current Ruby runtime as an MCBean" do
      ruby = @container['Ruby']
      ruby.should_not be_nil
      ruby.should be( JRuby.runtime )
    end

    it "should expose a ruby runtime factory as an MCBean" do
      factory = @container['RubyRuntimeFactory']
      factory.should_not be_nil
      ruby = factory.create
      ruby.should be( JRuby.runtime )
    end
  end

end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
org.torquebox.torquebox-container-foundation-1.0.0.Beta23-java spec/container_spec.rb
org.torquebox.torquebox-container-foundation-1.0.0.Beta22-java spec/container_spec.rb