Sha256: be86b79fc3577dad95dd58bc509c61216cdf283a36a5195d1ed171d75e89872a

Contents?: true

Size: 618 Bytes

Versions: 14

Compression:

Stored size: 618 Bytes

Contents

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

describe Thor::Shell do
  def shell
    @shell ||= Thor::Base.shell.new
  end

  describe "#initialize" do
    it "sets shell value" do
      base = MyCounter.new [1, 2], { }, :shell => shell
      base.shell.must == shell
    end

    it "sets the base value on the shell if an accessor is available" do
      base = MyCounter.new [1, 2], { }, :shell => shell
      shell.base.must == base
    end
  end

  describe "#shell" do
    it "returns the shell in use" do
      MyCounter.new([1,2]).shell.must be_kind_of(Thor::Base.shell)
    end
  end
end

Version data entries

14 entries across 14 versions & 3 rubygems

Version Path
wycats-thor-0.11.5 spec/shell_spec.rb
thor-0.13.3 spec/shell_spec.rb
thor-0.13.2 spec/shell_spec.rb
thor-0.13.1 spec/shell_spec.rb
thor-0.13.0 spec/shell_spec.rb
thor-0.12.3 spec/shell_spec.rb
thor-0.12.2 spec/shell_spec.rb
rango-0.0.6 vendor/thor/spec/shell_spec.rb
rango-0.1.pre vendor/thor/spec/shell_spec.rb
thor-0.12.0 spec/shell_spec.rb
thor-0.11.8 spec/shell_spec.rb
thor-0.11.7 spec/shell_spec.rb
thor-0.11.6 spec/shell_spec.rb
thor-0.11.5 spec/shell_spec.rb