class ApibuilderCli < Formula desc "Command-line interface to generate clients for api builder" homepage "https://www.apibuilder.io" url "https://github.com/apicollective/apibuilder-cli/archive/0.1.28.tar.gz" sha256 "e3215e0c6e24538f3f4d791ffa47866473ae46344de2a2e4787620723f615f9d" bottle :unneeded def install system "./install.sh", prefix end test do (testpath/"config").write <<~EOS [default] token = abcd1234 EOS assert_match "Profile default:", shell_output("#{bin}/read-config --path config") assert_match "Could not find apibuilder configuration directory", shell_output("#{bin}/apibuilder", 1) end end