diff options
| author | Xu Cheng | 2016-02-10 19:29:40 +0800 |
|---|---|---|
| committer | Xu Cheng | 2016-02-10 21:01:12 +0800 |
| commit | e5b6f79b221ecf539ff9ade285667ca729e6c7da (patch) | |
| tree | 992c9bd49480029c9fc085558a67682b37203c8a /Library/Homebrew/test | |
| parent | 2facb5166cec53ed6c45ce20f7e61c03aacb8765 (diff) | |
| download | brew-e5b6f79b221ecf539ff9ade285667ca729e6c7da.tar.bz2 | |
bottle: do not follow symlink when setting mtime
Also set atime to mtime, which seems to be a more common practice.
Fixes Homebrew/homebrew#49007
Closes Homebrew/homebrew#49027.
Signed-off-by: Xu Cheng <xucheng@me.com>
Diffstat (limited to 'Library/Homebrew/test')
| -rw-r--r-- | Library/Homebrew/test/test_integration_cmds.rb | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/Library/Homebrew/test/test_integration_cmds.rb b/Library/Homebrew/test/test_integration_cmds.rb index bca031f5f..ffdcaa8b5 100644 --- a/Library/Homebrew/test/test_integration_cmds.rb +++ b/Library/Homebrew/test/test_integration_cmds.rb @@ -152,6 +152,11 @@ class IntegrationCommandTests < Homebrew::TestCase url "https://example.com/testball-0.1.tar.gz" end EOS + # `brew bottle` should not fail with dead symlink + # https://github.com/Homebrew/homebrew/issues/49007 + (HOMEBREW_CELLAR/"testball/0.1").cd do + FileUtils.ln_s "not-exist", "symlink" + end assert_match(/testball-0\.1.*\.bottle\.tar\.gz/, cmd_output("bottle", "--no-revision", "testball")) ensure |
