Skip to content

Commit

Permalink
test: fix a couple failures on certain systems
Browse files Browse the repository at this point in the history
  • Loading branch information
Bo98 committed Dec 7, 2023
1 parent ab6a7ed commit d496da8
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
1 change: 1 addition & 0 deletions Library/Homebrew/test/caveats_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -284,6 +284,7 @@ def caveats
let(:caveats) { described_class.new(f).caveats }

it "adds the correct amount of new lines to the output" do
expect(Utils::Service).to receive(:launchctl?).at_least(1).times.and_return(true)
expect(caveats).to include("something else")
expect(caveats).to include("keg-only")
expect(caveats).to include("if you don't want/need a background service")
Expand Down
3 changes: 2 additions & 1 deletion Library/Homebrew/test/unpack_strategy_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,8 @@
it "does not make other files writable" do
strategy.extract_nestedly(to: unpack_dir)

expect(unpack_dir/executable).not_to be_writable
# We don't check `writable?` here as that's always true as root.
expect((unpack_dir/executable).stat.mode & 0222).to be_zero
end
end
end
Expand Down

0 comments on commit d496da8

Please sign in to comment.