Sha256: f9995c058625e34bf30a6222d644044bb6a856df7ce9a140d6367d4cc1187058
Contents?: true
Size: 689 Bytes
Versions: 24
Compression:
Stored size: 689 Bytes
Contents
require "spec_helper" describe Mongoid::Matchers::Lt do describe "#matches?" do context "when the value is larger" do let(:matcher) { Mongoid::Matchers::Lt.new(5) } it "returns false" do matcher.matches?("$lt" => 3).should be_false end end context "when the value is smaller" do let(:matcher) { Mongoid::Matchers::Lt.new(5) } it "returns true" do matcher.matches?("$lt" => 10).should be_true end end context "when the value is nil" do let(:matcher) { Mongoid::Matchers::Lt.new(nil) } it "returns false" do matcher.matches?("$lt" => 5).should be_false end end end end
Version data entries
24 entries across 24 versions & 3 rubygems