Sha256: 419392df478bcc745f3cca85caeff375a78baa7cdfbce0dc8bf45f1236292bd7
Contents?: true
Size: 587 Bytes
Versions: 5
Compression:
Stored size: 587 Bytes
Contents
require File.expand_path(File.dirname(__FILE__) + '/../../spec_helper') require 'hamster/set' describe Hamster::Set do [:include?, :member?].each do |method| describe "##{method}" do before do @set = Hamster.set("A", "B", "C", nil) end ["A", "B", "C", nil].each do |value| it "returns true for an existing value (#{value.inspect})" do @set.send(method, value).should be_true end end it "returns false for a non-existing value" do @set.send(method, "D").should be_false end end end end
Version data entries
5 entries across 5 versions & 1 rubygems