diff options
Diffstat (limited to 'Library/Homebrew/test/test_formula_pin.rb')
| -rw-r--r-- | Library/Homebrew/test/test_formula_pin.rb | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/Library/Homebrew/test/test_formula_pin.rb b/Library/Homebrew/test/test_formula_pin.rb index ebc51123c..515acdc0a 100644 --- a/Library/Homebrew/test/test_formula_pin.rb +++ b/Library/Homebrew/test/test_formula_pin.rb @@ -10,6 +10,14 @@ class FormulaPinTests < Homebrew::TestCase def rack Pathname.new("#{HOMEBREW_CELLAR}/#{name}") end + + def installed_prefixes + rack.directory? ? rack.subdirs : [] + end + + def installed_kegs + installed_prefixes.map { |d| Keg.new d } + end end def setup |
