rkflashtool: fix encoding issue in test

Closes Homebrew/homebrew#44145.

Signed-off-by: Dominyk Tiller <dominyktiller@gmail.com>
This commit is contained in:
Francisco Facioni 2015-09-19 16:29:52 -03:00 committed by Dominyk Tiller
parent b99dbe137c
commit 7b923e86d2

View file

@ -33,6 +33,8 @@ class Rkflashtool < Formula
test do
(testpath/"input.file").write "ABCD"
system bin/"rkcrc", "input.file", "output.file"
assert_equal "ABCD\264\366\a\t", `cat output.file`
result = shell_output("cat output.file")
result.force_encoding("UTF-8") if result.respond_to?(:force_encoding)
assert_equal "ABCD\264\366\a\t", result
end
end