From 769b4f89c7cd8c9f9d40a40ea9a7d950252dac20 Mon Sep 17 00:00:00 2001 From: apainintheneck Date: Wed, 20 Mar 2024 21:05:14 -0700 Subject: [PATCH] rubocops/service_spec: update test to cover custom name that requires root This was added in recently and this just updates the test to reflect the expected behavior for the cop. --- Library/Homebrew/test/rubocops/service_spec.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Library/Homebrew/test/rubocops/service_spec.rb b/Library/Homebrew/test/rubocops/service_spec.rb index 2c28212916..aa04b7355c 100644 --- a/Library/Homebrew/test/rubocops/service_spec.rb +++ b/Library/Homebrew/test/rubocops/service_spec.rb @@ -19,13 +19,14 @@ RSpec.describe RuboCop::Cop::FormulaAudit::Service do RUBY end - it "reports no offenses when a service block only includes custom names" do + it "reports no offenses when a service block includes custom names and requires root" do expect_no_offenses(<<~RUBY) class Foo < Formula url "https://brew.sh/foo-1.0.tgz" service do name macos: "custom.mcxl.foo", linux: "custom.foo" + require_root true end end RUBY