We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8602abb commit 7d3fc1fCopy full SHA for 7d3fc1f
test/zlib/test_zlib.rb
@@ -1276,11 +1276,20 @@ def test_crc_table
1276
end
1277
1278
def test_inflate
1279
- TestZlibInflate.new(__name__).test_inflate
+ s = Zlib::Deflate.deflate("foo")
1280
+ z = Zlib::Inflate.new
1281
+ s = z.inflate(s)
1282
+ s << z.inflate(nil)
1283
+ assert_equal("foo", s)
1284
+ z.inflate("foo") # ???
1285
+ z << "foo" # ???
1286
1287
1288
def test_deflate
- TestZlibDeflate.new(__name__).test_deflate
1289
1290
+ assert_equal("foo", Zlib::Inflate.inflate(s))
1291
+
1292
+ assert_raise(Zlib::StreamError) { Zlib::Deflate.deflate("foo", 10000) }
1293
1294
1295
def test_deflate_stream
0 commit comments