From deea4c82a4e64e746465cd74ea80e9afbedd9a91 Mon Sep 17 00:00:00 2001 From: Xu Cheng Date: Fri, 26 Feb 2016 19:43:49 +0800 Subject: fix brew tests Fix the `brew tests` problem caused by core/formula separation. --- Library/Homebrew/test/test_tap.rb | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'Library/Homebrew/test/test_tap.rb') diff --git a/Library/Homebrew/test/test_tap.rb b/Library/Homebrew/test/test_tap.rb index 18fe8709d..fa0602e94 100644 --- a/Library/Homebrew/test/test_tap.rb +++ b/Library/Homebrew/test/test_tap.rb @@ -55,7 +55,7 @@ class TapTest < Homebrew::TestCase end def teardown - Tap::TAP_DIRECTORY.rmtree + @path.rmtree end def test_fetch @@ -68,7 +68,7 @@ class TapTest < Homebrew::TestCase end def test_names - assert_equal ["homebrew/foo"], Tap.names + assert_equal ["homebrew/core", "homebrew/foo"], Tap.names end def test_attributes @@ -95,6 +95,8 @@ class TapTest < Homebrew::TestCase (Tap::TAP_DIRECTORY/"someone/homebrew-no-git").mkpath assert_nil Tap.new("someone", "no-git").issues_url + ensure + path.parent.rmtree end def test_files @@ -132,6 +134,8 @@ class TapTest < Homebrew::TestCase end end refute_predicate version_tap, :private? + ensure + version_tap.path.rmtree end def test_remote_not_git_repo @@ -213,8 +217,8 @@ class CoreTapTest < Homebrew::TestCase def test_attributes assert_equal "Homebrew", @repo.user - assert_equal "homebrew", @repo.repo - assert_equal "Homebrew/homebrew", @repo.name + assert_equal "core", @repo.repo + assert_equal "homebrew/core", @repo.name assert_equal [], @repo.command_files assert_predicate @repo, :installed? refute_predicate @repo, :pinned? -- cgit v1.2.3