diff options
| author | Mike McQuaid | 2017-04-16 09:30:38 +0100 |
|---|---|---|
| committer | GitHub | 2017-04-16 09:30:38 +0100 |
| commit | 46f6dc4c93b96abd528c3a0a808a5ca5a795c7f3 (patch) | |
| tree | 517eea0bba7d3f06273f2958fe4f250b8a2ef141 /Library | |
| parent | 02f0189335907805d422c817462674081f48ab60 (diff) | |
| parent | 7e455a623a3f49f63b589ea31d72c860b1d33c06 (diff) | |
| download | brew-46f6dc4c93b96abd528c3a0a808a5ca5a795c7f3.tar.bz2 | |
Merge pull request #2446 from mansimarkaur/diagnostic_tests1.1.13
[WIP] Added test for check_access_lock_dir
Diffstat (limited to 'Library')
| -rw-r--r-- | Library/Homebrew/test/diagnostic_spec.rb | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/Library/Homebrew/test/diagnostic_spec.rb b/Library/Homebrew/test/diagnostic_spec.rb index 59560127c..c2bcdb9c0 100644 --- a/Library/Homebrew/test/diagnostic_spec.rb +++ b/Library/Homebrew/test/diagnostic_spec.rb @@ -41,6 +41,18 @@ describe Homebrew::Diagnostic::Checks do end end + specify "#check_access_lock_dir" do + begin + mode = HOMEBREW_LOCK_DIR.stat.mode & 0777 + HOMEBREW_LOCK_DIR.chmod 0555 + + expect(subject.check_access_lock_dir) + .to match("#{HOMEBREW_LOCK_DIR} isn't writable.") + ensure + HOMEBREW_LOCK_DIR.chmod mode + end + end + specify "#check_access_logs" do begin mode = HOMEBREW_LOGS.stat.mode & 0777 |
