From 96cffa012e95f4985de76838686dd631d08bb5ac Mon Sep 17 00:00:00 2001 From: Jack Nagel Date: Tue, 26 Mar 2013 10:51:05 -0500 Subject: git-tracker: improve test --- Library/Formula/git-tracker.rb | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'Library') diff --git a/Library/Formula/git-tracker.rb b/Library/Formula/git-tracker.rb index c642284dd..604ec83e9 100644 --- a/Library/Formula/git-tracker.rb +++ b/Library/Formula/git-tracker.rb @@ -11,7 +11,10 @@ class GitTracker < Formula rake 'standalone:install', "prefix=#{prefix}" end - def test - `#{bin}/git-tracker test-command`.chomp == 'git-tracker is here. How are you?' + test do + require 'open3' + Open3.popen3("#{bin}/git-tracker", "test-command") do |_, stdout, _| + "git-tracker is here. How are you?" == stdout.read.strip + end end end -- cgit v1.2.3