diff options
author | Nobuyoshi Nakada <nobu@ruby-lang.org> | 2021-02-03 17:32:41 +0900 |
---|---|---|
committer | Nobuyoshi Nakada <nobu@ruby-lang.org> | 2021-02-03 17:32:41 +0900 |
commit | d05a268adc402e0a9a5eac0ce291cfd34e68f29a (patch) | |
tree | 210ac5f31ba593c29837a3b75d1e90e451f63cff /test | |
parent | 583f364f7187337b284061b78a47b29875398e33 (diff) | |
download | ruby-d05a268adc402e0a9a5eac0ce291cfd34e68f29a.tar.gz |
Open gzip file in binary mode
Diffstat (limited to 'test')
-rw-r--r-- | test/zlib/test_zlib.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/test/zlib/test_zlib.rb b/test/zlib/test_zlib.rb index addd4270e1..42ee5c6638 100644 --- a/test/zlib/test_zlib.rb +++ b/test/zlib/test_zlib.rb @@ -516,14 +516,14 @@ if defined? Zlib gz.close results = [] - t = File.open(t.path) + t = File.open(t.path, 'rb') Zlib::GzipReader.zcat(t) do |str| results << str end assert_equal(["foo", "bar"], results) t.close - t = File.open(t.path) + t = File.open(t.path, 'rb') assert_equal("foobar", Zlib::GzipReader.zcat(t)) t.close } |