From e4d0187120e61bc80d31ebecc3b38f0740b20bb5 Mon Sep 17 00:00:00 2001
From: Andrea Kao <eirinikos@gmail.com>
Date: Wed, 1 Jun 2016 16:26:32 -0700
Subject: [PATCH] tests: extend cmd/home integration test (#305)

---
 Library/Homebrew/test/test_integration_cmds.rb | 14 ++++++++++++++
 1 file changed, 14 insertions(+)

diff --git a/Library/Homebrew/test/test_integration_cmds.rb b/Library/Homebrew/test/test_integration_cmds.rb
index df71258d66..a249146cf9 100644
--- a/Library/Homebrew/test/test_integration_cmds.rb
+++ b/Library/Homebrew/test/test_integration_cmds.rb
@@ -552,6 +552,20 @@ class IntegrationCommandTests < Homebrew::TestCase
   def test_home
     assert_equal HOMEBREW_WWW,
                  cmd("home", {"HOMEBREW_BROWSER" => "echo"})
+
+    formula_file = CoreTap.new.formula_dir/"testball.rb"
+    formula_file.write <<-EOS.undent
+      class Testball < Formula
+        desc "Some test"
+        homepage "https://example.com/testball"
+        url "https://example.com/testball-0.1.tar.gz"
+      end
+    EOS
+
+    assert_equal Formula["testball"].homepage,
+                 cmd("home", "testball", {"HOMEBREW_BROWSER" => "echo"})
+  ensure
+    formula_file.unlink
   end
 
   def test_list
-- 
GitLab