7 @string = WrappedString.new("foobar")
16 {"sub_test" => [@string],
21 class SubTest < Test::Unit::TestCase
23 data = SubTestData.new.to_eet
28 assert_nothing_raised do
29 stream = Eet::Stream.deserialize(data)
32 assert_equal(1, stream.length)
33 assert_equal("SubTest", stream.first.tag)
35 assert_nothing_raised do
36 stream = Eet::Stream.deserialize(stream.first.data)
39 assert_equal(1, stream.length)
40 assert_equal("sub_test", stream.first.tag)
42 assert_nothing_raised do
43 stream = Eet::Stream.deserialize(stream.first.data)
46 assert_equal(1, stream.length)
47 assert_equal("String", stream.first.tag)
49 assert_nothing_raised do
50 stream = Eet::Stream.deserialize(stream.first.data)
53 assert_equal(1, stream.length)
54 assert_equal("buf", stream.first.tag)
55 assert_equal("foobar\0", stream.first.data)