Sha256: 1a3e19a589b39a189ddb1216fe54d7d18cd5ca2a836a7a5301c670590fb5151d

Contents?: true

Size: 1.28 KB

Versions: 26

Compression:

Stored size: 1.28 KB

Contents

require 'spec/interop/test/unit/test_unit_spec_helper'

describe "ExampleGroup with test/unit/interop" do
  include TestUnitSpecHelper
    
  describe "with passing examples" do
    it "should output 0 failures" do
      output = ruby("#{resources}/spec_that_passes.rb")
      output.should include("1 example, 0 failures")
    end

    it "should return an exit code of 0" do
      ruby("#{resources}/spec_that_passes.rb")
      $?.should == 0
    end
  end

  describe "with failing examples" do
    it "should output 1 failure" do
      output = ruby("#{resources}/spec_that_fails.rb")
      output.should include("1 example, 1 failure")
    end

    it "should return an exit code of 256" do
      ruby("#{resources}/spec_that_fails.rb")
      $?.should == 256
    end
  end

  describe "with example that raises an error" do
    it "should output 1 failure" do
      output = ruby("#{resources}/spec_with_errors.rb")
      output.should include("1 example, 1 failure")
    end

    it "should return an exit code of 256" do
      ruby("#{resources}/spec_with_errors.rb")
      $?.should == 256
    end
  end
  
  describe "options hash" do
    it "should be exposed" do
      output = ruby("#{resources}/spec_with_options_hash.rb")
      output.should include("1 example, 0 failures")
    end
  end
end

Version data entries

26 entries across 26 versions & 9 rubygems

Version Path
hubbub-0.0.11 lib/vendor/plugins/rspec/spec/spec/interop/test/unit/spec_spec.rb
hubbub-0.0.10 lib/vendor/plugins/rspec/spec/spec/interop/test/unit/spec_spec.rb
hubbub-0.0.9 lib/vendor/plugins/rspec/spec/spec/interop/test/unit/spec_spec.rb
hubbub-0.0.8 lib/vendor/plugins/rspec/spec/spec/interop/test/unit/spec_spec.rb
hubbub-0.0.6 lib/vendor/plugins/rspec/spec/spec/interop/test/unit/spec_spec.rb
simple-templater-0.0.1.4 gems/gems/rspec-1.2.9/spec/spec/interop/test/unit/spec_spec.rb
media-path-0.1.2 vendor/rspec/spec/spec/interop/test/unit/spec_spec.rb
simple-templater-0.0.1.3 vendor/rspec/spec/spec/interop/test/unit/spec_spec.rb
pupu-0.0.2.pre vendor/rspec/spec/spec/interop/test/unit/spec_spec.rb
media-path-0.1.1.pre vendor/rspec/spec/spec/interop/test/unit/spec_spec.rb
simple-templater-0.0.1.2 vendor/rspec/spec/spec/interop/test/unit/spec_spec.rb
media-path-0.1.1 vendor/rspec/spec/spec/interop/test/unit/spec_spec.rb
simple-templater-0.0.1.1 vendor/rspec/spec/spec/interop/test/unit/spec_spec.rb
pupu-0.0.2 vendor/rspec/spec/spec/interop/test/unit/spec_spec.rb
rango-0.0.6 vendor/rspec/spec/spec/interop/test/unit/spec_spec.rb
rango-0.1.pre vendor/rspec/spec/spec/interop/test/unit/spec_spec.rb
pupu-0.0.1 vendor/rspec/spec/spec/interop/test/unit/spec_spec.rb
media-path-0.1 vendor/rspec/spec/spec/interop/test/unit/spec_spec.rb
simple-templater-0.0.1 vendor/rspec/spec/spec/interop/test/unit/spec_spec.rb
middleman-0.10.17 vendor/gems/gems/rspec-1.2.9/spec/spec/interop/test/unit/spec_spec.rb