Sha256: 56872fb1b5c9e189ba59c44db38a59b7dcd413e1bffaac5c237566e2d5d727d4

Contents?: true

Size: 805 Bytes

Versions: 2

Compression:

Stored size: 805 Bytes

Contents

require 'spec_helper'
require 'stringio'

describe RSpec::Core::Formatters::ProgressFormatter do

   before do
     @output = StringIO.new
     @formatter = RSpec::Core::Formatters::ProgressFormatter.new(@output)
     @formatter.start(2)
     @formatter.stub!(:color_enabled?).and_return(false)
   end

   it "should produce line break on start dump" do
     @formatter.start_dump
     @output.string.should == "\n"
   end

   it "should produce standard summary without pending when pending has a 0 count" do
     @formatter.start_dump
     @formatter.dump_summary(0.00001, 2, 0, 0)
     @output.string.should =~ /2 examples, 0 failures/i
     @output.string.should_not =~ /0 pending/i
   end

   it "should push nothing on start" do
     @formatter.start(4)
     @output.string.should == ""
   end

end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
rspec-core-2.0.0.beta.19 spec/rspec/core/formatters/progress_formatter_spec.rb
rspec-core-2.0.0.beta.18 spec/rspec/core/formatters/progress_formatter_spec.rb