From c61d1f1b3d2eb223eddf077977e9f155e6f4acb3 Mon Sep 17 00:00:00 2001 From: Jack Nagel Date: Tue, 26 Mar 2013 11:00:57 -0500 Subject: mp3fs: improve test --- Library/Formula/mp3fs.rb | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'Library/Formula') diff --git a/Library/Formula/mp3fs.rb b/Library/Formula/mp3fs.rb index 2a8416b47..b025a6543 100644 --- a/Library/Formula/mp3fs.rb +++ b/Library/Formula/mp3fs.rb @@ -17,7 +17,10 @@ class Mp3fs < Formula system "make install" end - def test - system "#{bin}/mp3fs -V | grep MP3FS && true || false" + test do + require 'open3' + Open3.popen3("#{bin}/mp3fs", "-V") do |_, stdout, _| + /MP3FS version #{Regexp.escape(version)}/ === stdout.read + end end end -- cgit v1.2.3