added RSpec and RSpec on Rails

This commit is contained in:
Xin Zheng 2008-01-22 16:39:09 +00:00
parent ddd5b4cf19
commit 3f607d565b
316 changed files with 23828 additions and 0 deletions

View file

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