From e5ba31fcdcc4150e5aa8ecf110cfa502dd62a802 Mon Sep 17 00:00:00 2001 From: Mike McQuaid Date: Mon, 14 Dec 2015 19:47:19 +0000 Subject: Allow multiple option_names in dep/reqs. This means that dependencies can be merged but still maintain all their option names. Closes Homebrew/homebrew#46916. Signed-off-by: Mike McQuaid --- Library/Homebrew/test/test_dependency.rb | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'Library/Homebrew/test/test_dependency.rb') diff --git a/Library/Homebrew/test/test_dependency.rb b/Library/Homebrew/test/test_dependency.rb index 8e647c1b0..f58a22fd8 100644 --- a/Library/Homebrew/test/test_dependency.rb +++ b/Library/Homebrew/test/test_dependency.rb @@ -49,13 +49,13 @@ class DependencyTests < Homebrew::TestCase foo_named_dep = merged.find {|d| d.name == "foo"} assert_equal [:build, "bar"], foo_named_dep.tags - assert_includes foo_named_dep.option_name, "foo" - assert_includes foo_named_dep.option_name, "foo2" + assert_includes foo_named_dep.option_names, "foo" + assert_includes foo_named_dep.option_names, "foo2" xyz_named_dep = merged.find {|d| d.name == "xyz"} assert_equal ["abc"], xyz_named_dep.tags - assert_includes xyz_named_dep.option_name, "foo" - refute_includes xyz_named_dep.option_name, "foo2" + assert_includes xyz_named_dep.option_names, "foo" + refute_includes xyz_named_dep.option_names, "foo2" end def test_equality @@ -73,8 +73,8 @@ class DependencyTests < Homebrew::TestCase end class TapDependencyTests < Homebrew::TestCase - def test_option_name + def test_option_names dep = TapDependency.new("foo/bar/dog") - assert_equal "dog", dep.option_name + assert_equal %w[dog], dep.option_names end end -- cgit v1.2.3