class So::DSL

Public Instance Methods

all(*args) click to toggle source
# File lib/spec_object.rb, line 421
def all(*args)
  And.and_(*args)
end
both(a, b) click to toggle source
# File lib/spec_object.rb, line 417
def both(a, b)
  And.and_(a, b)
end
either(a, b) click to toggle source
# File lib/spec_object.rb, line 425
def either(a, b)
  a = a.to_so_expr
  b = b.to_so_expr

  !both(!a, !b)
end
exist(&blk) click to toggle source
# File lib/spec_object.rb, line 408
def exist(&blk)
  v = Variable.new
  Exists.new(v, blk.call(v))
end
ite(c, t, f) click to toggle source
# File lib/spec_object.rb, line 432
def ite(c, t, f)
  c = c.to_so_expr

  either(both(c, t), both(!c, f))
end
received(method) click to toggle source
# File lib/spec_object.rb, line 413
def received(method)
  Received.new(method)
end