Sha256: 1d36fb6f1a16aae334491a8cbcbcf1a5186b7595acb9cd91851f5ecb879660fb

Contents?: true

Size: 586 Bytes

Versions: 10

Compression:

Stored size: 586 Bytes

Contents

require "spec_helper"

describe ORS::Command do

  subject { ORS::Command }

  context ".run" do

    it "should execute help when the command is help" do
      mock(ORS::Commands::Help).new { mock!.execute.subject }
      subject.run ["help"]
    end

    it "should execute help when no command is given" do
      mock(ORS::Commands::Help).new { mock!.execute.subject }
      subject.run []
    end

    it "should execute help when an unknown command is given" do
      mock(ORS::Commands::Help).new { mock!.execute.subject }
      subject.run ["as0d9fja0s9djf"]
    end

  end

end

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
ors-0.1.0 spec/ors/command_spec.rb
ors-0.0.9 spec/ors/command_spec.rb
ors-0.0.8 spec/ors/command_spec.rb
ors-0.0.7 spec/ors/command_spec.rb
ors-0.0.6 spec/ors/command_spec.rb
ors-0.0.5 spec/ors/command_spec.rb
ors-0.0.4 spec/ors/command_spec.rb
ors-0.0.3 spec/ors/command_spec.rb
ors-0.0.2 spec/ors/command_spec.rb
ors-0.0.1 spec/ors/command_spec.rb