Sha256: 6a56ff7ebbb32e5dda97c26c4be8993d777bc5cf760a150040ca20800482b27a

Contents?: true

Size: 567 Bytes

Versions: 8

Compression:

Stored size: 567 Bytes

Contents

module Spec
  module Example      
    module Pending
      def pending(message = "TODO")
        pending_caller = caller[0]
        if block_given?
          begin
            yield
          rescue Exception => e
            raise Spec::Example::ExamplePendingError.new(message, pending_caller)
          end
          raise Spec::Example::PendingExampleFixedError.new("Expected pending '#{message}' to fail. No Error was raised.")
        else
          raise Spec::Example::ExamplePendingError.new(message, pending_caller)
        end
      end
    end
  end
end

Version data entries

8 entries across 8 versions & 2 rubygems

Version Path
dchelimsky-rspec-1.1.99.13 lib/spec/example/pending.rb
dchelimsky-rspec-1.1.99.6 lib/spec/example/pending.rb
dchelimsky-rspec-1.1.99.7 lib/spec/example/pending.rb
dchelimsky-rspec-1.1.99.8 lib/spec/example/pending.rb
dchelimsky-rspec-1.1.99.9 lib/spec/example/pending.rb
rspec-1.2.2 lib/spec/example/pending.rb
rspec-1.2.1 lib/spec/example/pending.rb
rspec-1.2.0 lib/spec/example/pending.rb