test/test_blocker.rb in binaryparse-1.0.1 vs test/test_blocker.rb in binaryparse-1.1.0
- old
+ new
@@ -47,11 +47,11 @@
def test_failed_deblock
bb = BBTest2.new
bb.bar = 21
buf = bb.block
- buf[0] = 0
+ buf[0] = 0.chr
bb2 = BBTest2.new
status = bb2.deblock(StringIO.new(buf))
assert(!status)
@@ -544,13 +544,13 @@
ib = ItemB.new
ib.name = 'widget B'
bb.items << ia << ib
b2 = bb.clone
- assert(13, b2.header)
+ assert_equal(13, b2.header)
b2.header = 21
- assert(21, b2.header)
- assert(13, bb.header)
+ assert_equal(21, b2.header)
+ assert_equal(13, bb.header)
end
class Nested < BinaryBlocker::Blocker
has_one :name, :string, :length => 20
end