Class: Object

Inherits:
BasicObject
Defined in:
lib/test/spec.rb

Overview

– Global helpers

Instance Method Summary collapse

Instance Method Details

#should(*args) ⇒ Object



472
473
474
475
476
477
478
479
480
481
# File 'lib/test/spec.rb', line 472

def should(*args)
  case args.size
  when 0
    Test::Spec::Should.new(self)
  when 1
    Test::Spec::Should.new(self).pass(args.first)
  else
    raise ArgumentError, "Object#should takes zero or one argument(s)."
  end
end