aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Formula/libvbucket.rb
diff options
context:
space:
mode:
authorAdam Vandenberg2014-05-04 12:12:41 -0700
committerAdam Vandenberg2014-08-01 07:58:10 -0700
commitff86702dd85eab420f6f58e8dcf8375dae4b22b9 (patch)
treee0071c9d3604ab8d311679aa77ce9cce90da962f /Library/Formula/libvbucket.rb
parent1dc876667538fb33ebc9eb30edd3bc9b530592a6 (diff)
downloadhomebrew-ff86702dd85eab420f6f58e8dcf8375dae4b22b9.tar.bz2
use test helpers
Diffstat (limited to 'Library/Formula/libvbucket.rb')
-rw-r--r--Library/Formula/libvbucket.rb8
1 files changed, 2 insertions, 6 deletions
diff --git a/Library/Formula/libvbucket.rb b/Library/Formula/libvbucket.rb
index 4ca8624f5..c747d6579 100644
--- a/Library/Formula/libvbucket.rb
+++ b/Library/Formula/libvbucket.rb
@@ -22,7 +22,6 @@ class Libvbucket < Formula
test do
require 'utils/json'
- require 'open3'
json = Utils::JSON.dump(
{
"hashAlgorithm" => "CRC",
@@ -37,10 +36,7 @@ class Libvbucket < Formula
key: world master: server2:11210 vBucketId: 3 couchApiBase: (null) replicas: server3:11211 server1:11211
EOS
- Open3.popen3("#{bin}/vbuckettool", "-", "hello", "world") do |stdin, stdout, _|
- stdin.write(json)
- stdin.close
- assert_equal expected, stdout.read
- end
+ output = pipe_output("#{bin}/vbuckettool - hello world", json)
+ assert_equal expected, output
end
end