
We added the `--all` flag (now renamed to `--eval-all`) for various commands for this behaviour so let's start deprecating this. Also, introduce a `HOMEBREW_EVAL_ALL` environment variable to use the existing, less secure, behaviour by default and avoid passing `--eval-all` everywhere.
23 lines
576 B
Ruby
23 lines
576 B
Ruby
# typed: false
|
|
# frozen_string_literal: true
|
|
|
|
require "cmd/shared_examples/args_parse"
|
|
|
|
describe "brew uses" do
|
|
it_behaves_like "parseable arguments"
|
|
|
|
it "prints the Formulae a given Formula is used by", :integration_test do
|
|
setup_test_formula "foo"
|
|
setup_test_formula "bar"
|
|
setup_test_formula "baz", <<~RUBY
|
|
url "https://brew.sh/baz-1.0"
|
|
depends_on "bar"
|
|
RUBY
|
|
|
|
expect { brew "uses", "--eval-all", "--recursive", "foo" }
|
|
.to output(/(bar\nbaz|baz\nbar)/).to_stdout
|
|
.and not_to_output.to_stderr
|
|
.and be_a_success
|
|
end
|
|
end
|