Permalink
Browse files

Added a spec for CharSet#include?.

  • Loading branch information...
postmodern committed Jul 11, 2012
1 parent 4e9ed14 commit ebb458fc07d9c70ba46dcedf3d38fd7fe932a0cb
Showing with 14 additions and 4 deletions.
  1. +14 −4 spec/char_set_spec.rb
View
@@ -49,12 +49,22 @@
end
end
- it "should include Strings" do
- @char_set.include_char?('A').should == true
+ it "should include characters" do
+ @char_set.include_char?('A').should be_true
end
- it "should include Integers" do
- @char_set.should include(0x41)
+ it "should include bytes" do
+ @char_set.include_byte?(0x41).should be_true
+ end
+
+ describe "#include?" do
+ it "should accept characters" do
+ @char_set.should include('A')
+ end
+
+ it "should accept bytes" do
+ @char_set.should include(0x41)
+ end
end
it "should be able to select bytes" do

0 comments on commit ebb458f

Please sign in to comment.