diff --git a/Library/Homebrew/cmd/help.rb b/Library/Homebrew/cmd/help.rb index 2d286ad465..66d1ec8dac 100644 --- a/Library/Homebrew/cmd/help.rb +++ b/Library/Homebrew/cmd/help.rb @@ -1,11 +1,16 @@ -# typed: strict +# typed: strong # frozen_string_literal: true +require "abstract_command" require "help" module Homebrew - sig { returns(T.noreturn) } - def help - Help.help + module Cmd + class HelpCmd < AbstractCommand + sig { override.void } + def run + Help.help + end + end end end diff --git a/Library/Homebrew/test/cmd/help_spec.rb b/Library/Homebrew/test/cmd/help_spec.rb index ff82501f5a..236a640690 100644 --- a/Library/Homebrew/test/cmd/help_spec.rb +++ b/Library/Homebrew/test/cmd/help_spec.rb @@ -1,6 +1,8 @@ # frozen_string_literal: true -RSpec.describe "brew", :integration_test do +require "cmd/help" + +RSpec.describe Homebrew::Cmd::HelpCmd, :integration_test do describe "help" do it "prints help for a documented Ruby command" do expect { brew "help", "cat" }