Add context method as describe alias

This commit is contained in:
ryo katsuma
2013-09-22 00:27:46 +09:00
committed by Watson
parent c4d79513cf
commit 6429c09a3c

View File

@@ -586,6 +586,8 @@ module Bacon
def raise?(*args, &block); block.raise?(*args); end
def throw?(*args, &block); block.throw?(*args); end
def change?(*args, &block); block.change?(*args); end
alias_method :context, :describe
end
end
@@ -643,6 +645,8 @@ module Kernel
private
def describe(*args, &block) Bacon::Context.new(args.join(' '), &block) end
def shared(name, &block) Bacon::Shared[name] = block end
alias_method :context, :describe
end
class Should