diff options
Diffstat (limited to 'test/ruby/test_pack.rb')
-rw-r--r-- | test/ruby/test_pack.rb | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/test/ruby/test_pack.rb b/test/ruby/test_pack.rb index 95f8e35226..658208d9df 100644 --- a/test/ruby/test_pack.rb +++ b/test/ruby/test_pack.rb @@ -802,6 +802,13 @@ EXPECTED assert_warning(/\A(.* in '\u{3042}'\n)+\z/) { [].pack("\u{3042}") } + + assert_warning(/\A.* in '.*U'\Z/) { + assert_equal "\000", [0].pack("\0U") + } + assert_warning(/\A.* in '.*U'\Z/) { + "\000".unpack("\0U") + } end def test_pack_resize |