Sha256: 10ab589db81d2a0199ee0a3644755ec8a5ea61c243dc434ca3a964b31b22577e

Contents?: true

Size: 798 Bytes

Versions: 10

Compression:

Stored size: 798 Bytes

Contents

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

module Spec
  module Runner
    module Formatter
      describe "FailingBehavioursFormatter" do
        before(:each) do
          @io = StringIO.new
          @formatter = FailingBehavioursFormatter.new(@io)
        end

        it "should add example name for each failure" do
          @formatter.add_behaviour("b 1")
          @formatter.example_failed("e 1", nil, Reporter::Failure.new(nil, RuntimeError.new))
          @formatter.add_behaviour("b 2")
          @formatter.example_failed("e 2", nil, Reporter::Failure.new(nil, RuntimeError.new))
          @formatter.example_failed("e 3", nil, Reporter::Failure.new(nil, RuntimeError.new))
          @io.string.should eql(<<-EOF
b 1
b 2
EOF
)
        end
      end
    end
  end
end

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
rspec-0.9.2 spec/spec/runner/formatter/failing_behaviours_formatter_spec.rb
rspec-0.9.0 spec/spec/runner/formatter/failing_behaviours_formatter_spec.rb
rspec-0.9.1 spec/spec/runner/formatter/failing_behaviours_formatter_spec.rb
rspec-0.9.3 spec/spec/runner/formatter/failing_behaviours_formatter_spec.rb
rspec-0.9.4 spec/spec/runner/formatter/failing_behaviours_formatter_spec.rb
rspec-1.0.0 spec/spec/runner/formatter/failing_behaviours_formatter_spec.rb
rspec-1.0.1 spec/spec/runner/formatter/failing_behaviours_formatter_spec.rb
rspec-1.0.2 spec/spec/runner/formatter/failing_behaviours_formatter_spec.rb
rspec-1.0.3 spec/spec/runner/formatter/failing_behaviours_formatter_spec.rb
rspec-1.0.4 spec/spec/runner/formatter/failing_behaviours_formatter_spec.rb