completions: fix tests

Signed-off-by: botantony <antonsm21@gmail.com>
This commit is contained in:
botantony 2025-04-22 22:31:45 +02:00
parent d15461608f
commit 2a03f2059c
No known key found for this signature in database
GPG Key ID: 7FE721557EA6AAD6

View File

@ -332,7 +332,7 @@ RSpec.describe Homebrew::Completions do
'--quiet[Make some output more quiet]' \\ '--quiet[Make some output more quiet]' \\
'--verbose[Make some output more verbose]' \\ '--verbose[Make some output more verbose]' \\
- formula \\ - formula \\
'*::formula:__brew_formulae' '*:formula:__brew_formulae'
} }
COMPLETION COMPLETION
end end
@ -357,10 +357,10 @@ RSpec.describe Homebrew::Completions do
it "returns appropriate completion for a command with multiple named arg types" do it "returns appropriate completion for a command with multiple named arg types" do
completion = described_class.generate_zsh_subcommand_completion("livecheck") completion = described_class.generate_zsh_subcommand_completion("livecheck")
expect(completion).to match( expect(completion).to match(
/'*::formula:__brew_formulae'/, /'*:formula:__brew_formulae'/,
) )
expect(completion).to match( expect(completion).to match(
/'*::cask:__brew_casks'\n}$/, /'*:cask:__brew_casks'\n}$/,
) )
end end
end end