diff options
| author | Jack Nagel | 2013-01-23 00:26:28 -0600 | 
|---|---|---|
| committer | Jack Nagel | 2013-01-26 12:14:46 -0600 | 
| commit | 7a8935455b43273291b37d2e2f62757bb8fa705e (patch) | |
| tree | 427b6275b89d249d1b3d6a4d54a58ea96c968c43 /Library/Homebrew/test | |
| parent | 0551dedf795c7516fd9c11cceeecfa93e4ff3fe3 (diff) | |
| download | homebrew-7a8935455b43273291b37d2e2f62757bb8fa705e.tar.bz2 | |
FormulaInstaller: allow formulae to pass options to deps
Formulae can now pass build options to dependencies. The following
syntax is supported:
  depends_on 'foo' => 'with-bar'
  depends_on 'foo' => ['with-bar', 'with-baz']
If a dependency is already installed but lacks the required build
options, an exception is raised. Eventually we may be able to just stash
the existing keg and reinstall it with the combined set of used_options
and passed options, but enabling that is left for another day.
Diffstat (limited to 'Library/Homebrew/test')
| -rw-r--r-- | Library/Homebrew/test/test_dependency.rb | 3 | ||||
| -rw-r--r-- | Library/Homebrew/test/test_dependency_collector.rb | 1 | 
2 files changed, 3 insertions, 1 deletions
diff --git a/Library/Homebrew/test/test_dependency.rb b/Library/Homebrew/test/test_dependency.rb index a043c1bd5..b9dbb35c8 100644 --- a/Library/Homebrew/test/test_dependency.rb +++ b/Library/Homebrew/test/test_dependency.rb @@ -1,5 +1,6 @@  require 'testing_env'  require 'dependencies' +require 'options'  class DependableTests < Test::Unit::TestCase    def setup @@ -8,7 +9,7 @@ class DependableTests < Test::Unit::TestCase    end    def test_options -    assert_equal %w{--foo --bar}.sort, @dep.options.sort +    assert_equal %w{--foo --bar}.sort, @dep.options.as_flags.sort    end    def test_interrogation diff --git a/Library/Homebrew/test/test_dependency_collector.rb b/Library/Homebrew/test/test_dependency_collector.rb index ded49f91f..3403fc089 100644 --- a/Library/Homebrew/test/test_dependency_collector.rb +++ b/Library/Homebrew/test/test_dependency_collector.rb @@ -1,5 +1,6 @@  require 'testing_env'  require 'dependencies' +require 'options'  require 'extend/set'  module DependencyCollectorTestExtension  | 
