Skip to content

Conversation

@drewda
Copy link

@drewda drewda commented Jan 3, 2026

  • Have you followed the guidelines for contributing?
  • Have you ensured that your commits follow the commit style guide?
  • Have you checked that there aren't other open pull requests for the same formula update/change?
  • Have you built your formula locally with HOMEBREW_NO_INSTALL_FROM_API=1 brew install --build-from-source <formula>, where <formula> is the name of the formula you're submitting?
  • Is your test running fine brew test <formula>, where <formula> is the name of the formula you're submitting?
  • Does your build pass brew audit --strict <formula> (after doing HOMEBREW_NO_INSTALL_FROM_API=1 brew install --build-from-source <formula>)? If this is a new formula, does it pass brew audit --new <formula>?

A note on the last task: I do receive the following offense, but this seems to be the same way other source-based formulas reference GitHub. If I'm misinterpreting how to do this, would a maintainer please advise?

brew audit --new utiluti
utiluti
  * line 4, col 3: https://github.com/scriptingosx/utiluti/archive/refs/tags/v1.3.tar.gz looks like a binary package, not a source archive; homebrew/core is source-only.
Error: 1 problem in 1 formula detected.

replacing mistake in Homebrew/brew#21355

closes scriptingosx/utiluti#6

@github-actions github-actions bot added new formula PR adds a new formula to Homebrew/homebrew-core swift Swift use is a significant feature of the PR or issue macos-only Formula depends on macOS labels Jan 3, 2026
@github-actions
Copy link
Contributor

github-actions bot commented Jan 3, 2026

Thanks for contributing to Homebrew! 🎉 It looks like you're having trouble with a CI failure. See our contribution guide for help. You may be most interested in the section on dealing with CI failures. You can find the CI logs in the Checks tab of your pull request.

@github-actions github-actions bot added the automerge-skip `brew pr-automerge` will skip this pull request label Jan 3, 2026
end

test do
assert_match version.to_s, shell_output("#{bin}/utiluti --version")
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We need a test that exercises the some of the functionality of the app. Version checks or usage checks (foo --version or foo --help) are not sufficient, as explained in the formula cookbook.

In most cases, a good test would involve running a simple test case: run #{bin}/foo input.txt.

  • Then you can check that the output is as expected (with assert_equal or assert_match on the output of shell_output)
  • You can also check that an output file was created, if that is expected: assert_predicate testpath/"output.txt", :exist?

Some advice for specific cases:

  • If the formula is a library, compile and run some simple code that links against it. It could be taken from upstream's documentation / source examples.
  • If the formula is for a GUI program, try to find some function that runs as command-line only, like a format conversion, reading or displaying a config file, etc.
  • If the software cannot function without credentials, a test could be to try to connect with invalid credentials (or without credentials) and confirm that it fails as expected.
  • Same if the software requires a virtual machine, docker instance, etc. to be running.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@bevanjkay Sorry, force pushed over you making the same change 😅

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you both for the prompt responses! I've added a more meaningful test assertion

utiluti: add to `not_a_binary_url_prefix_allowlist`
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

automerge-skip `brew pr-automerge` will skip this pull request macos-only Formula depends on macOS new formula PR adds a new formula to Homebrew/homebrew-core swift Swift use is a significant feature of the PR or issue

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Brew Installation

3 participants