aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Homebrew/test/test_integration_cmds.rb
diff options
context:
space:
mode:
authorMike McQuaid2016-09-08 20:16:29 +0100
committerGitHub2016-09-08 20:16:29 +0100
commitf37d004ab5588d7b24a593ad8619f024b8c91a6b (patch)
tree8651ed80d01cc2e23a28a6c8b389f0f09bf5f577 /Library/Homebrew/test/test_integration_cmds.rb
parent495419a4ee0456e592bd32906b2d4a4cfa9dbf99 (diff)
parent846fa231564ce956203d5588784740e1ab0e8eb6 (diff)
downloadbrew-f37d004ab5588d7b24a593ad8619f024b8c91a6b.tar.bz2
Merge pull request #864 from vladshablinsky/skip-upgrade
Skip upgrade of pinned dependency if it's outdated
Diffstat (limited to 'Library/Homebrew/test/test_integration_cmds.rb')
-rw-r--r--Library/Homebrew/test/test_integration_cmds.rb12
1 files changed, 12 insertions, 0 deletions
diff --git a/Library/Homebrew/test/test_integration_cmds.rb b/Library/Homebrew/test/test_integration_cmds.rb
index 9ea305344..ead87c8ab 100644
--- a/Library/Homebrew/test/test_integration_cmds.rb
+++ b/Library/Homebrew/test/test_integration_cmds.rb
@@ -529,6 +529,18 @@ class IntegrationCommandTests < Homebrew::TestCase
assert foo_dir.exist?
end
+ def test_reinstall_pinned
+ setup_test_formula "testball"
+
+ HOMEBREW_CELLAR.join("testball/0.1").mkpath
+ HOMEBREW_LIBRARY.join("PinnedKegs").mkpath
+ FileUtils.ln_s HOMEBREW_CELLAR.join("testball/0.1"), HOMEBREW_LIBRARY.join("PinnedKegs/testball")
+
+ assert_match "testball is pinned. You must unpin it to reinstall.", cmd("reinstall", "testball")
+
+ HOMEBREW_LIBRARY.join("PinnedKegs").rmtree
+ end
+
def test_home
setup_test_formula "testball"