blob: acf6d820560a79a22849112b28db83f6ae21c52f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
  | 
require "formula"
class Aha < Formula
  homepage "https://github.com/theZiz/aha"
  url "https://github.com/theZiz/aha/archive/0.4.7.2.tar.gz"
  sha1 "09933fddb02b3129a690eb3d7d140edb97ac0627"
  def install
    system "make"
    bin.install "aha"
  end
  test do
    IO.popen("#{bin}/aha", "w+") do |pipe|
      pipe.write("[35mrain[34mpill[00m")
      pipe.close_write
      assert_match /color:purple;">rain.*color:blue;">pill/, pipe.read
    end
  end
end
  |