Method: AE::Legacy::Assertions#assert_same

Defined in:
lib/ae/legacy.rb

#assert_same(exp, act, msg = nil) ⇒ Object

Passes if actual .equal? expected (i.e. they are the same instance).

o = Object.new
assert_same(o, o)


220
221
222
223
224
# File 'lib/ae/legacy.rb', line 220

def assert_same(exp, act, msg=nil)
  msg  = "Expected #{act.inspect} to be the same as #{exp.inspect}" unless msg
  test = exp.equal?(act)
  __assert__(test, msg)
end