lrzip: add test
Closes Homebrew/homebrew#28461. Signed-off-by: Adam Vandenberg <flangy@gmail.com>master
parent
8586a681f4
commit
d036365d16
|
@ -14,4 +14,18 @@ class Lrzip < Formula
|
|||
system "make"
|
||||
system "make install"
|
||||
end
|
||||
|
||||
test do
|
||||
path = testpath/"data.txt"
|
||||
original_contents = "." * 1000
|
||||
path.write original_contents
|
||||
|
||||
# compress: data.txt -> data.txt.lrz
|
||||
system bin/"lrzip", "-o", "#{path}.lrz", path
|
||||
path.unlink
|
||||
|
||||
# decompress: data.txt.lrz -> data.txt
|
||||
system bin/"lrzip", "-d", "#{path}.lrz"
|
||||
assert_equal original_contents, path.read
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue