Skip to content

Commit

Permalink
beakerlib 1.29.3 (new formula)
Browse files Browse the repository at this point in the history
Signed-off-by: Cristian Le <[email protected]>
  • Loading branch information
LecrisUT committed Feb 27, 2024
1 parent 35bf45c commit d788234
Showing 1 changed file with 26 additions and 0 deletions.
26 changes: 26 additions & 0 deletions Formula/b/beakerlib.rb
@@ -0,0 +1,26 @@
class Beakerlib < Formula
desc "Shell-level integration testing library"
homepage "https://github.com/beakerlib/beakerlib"
url "https://github.com/beakerlib/beakerlib/archive/refs/tags/1.29.3.tar.gz"
sha256 "f792b86bac8be1a4593dd096c32c1a061102c802c6f5760259a5753b13f6caa1"
license "GPL-2.0-only"

def install
system "make", "DD=#{prefix}", "install"
end

test do
(testpath/"test.sh").write <<~EOS
#!/usr/bin/env bash
source #{prefix}/share/beakerlib/beakerlib.sh || exit 1
rlJournalStart
rlPhaseStartTest
rlPass "All works"
rlPhaseEnd
rlJournalEnd
EOS
expected = /\[\s*PASS\s*\]\s*::\s*All works/
assert_match expected, shell_output("bash #{testpath}/test.sh 2>&1", 1)
end
end

0 comments on commit d788234

Please sign in to comment.