blob: 16badf6b36369c5989f36ee372970a6fc31e52de (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
  | 
require "formula"
class Flow < Formula
  homepage "http://flowtype.org/"
  url "https://github.com/facebook/flow/archive/v0.1.2.tar.gz"
  sha1 "776dd272707c4c640c44aeb127e5485f977c803f"
  head "https://github.com/facebook/flow.git"
  bottle do
    cellar :any
    sha1 "1f4f7135e772c874ccf07c628889bfd4efbd2ff9" => :yosemite
    sha1 "c5897b2f28f2e29ff4da42c38af985770610c998" => :mavericks
    sha1 "30a70f252b1e4ed356806edaec243d94c4b61668" => :mountain_lion
  end
  depends_on "objective-caml" => :build
  def install
    system "make"
    bin.install "bin/flow"
    (share/"flow").install "bin/examples"
  end
  test do
    output = `#{bin}/flow single #{share}/flow/examples/01_HelloWorld`
    assert_match(/This type is incompatible with/, output)
    assert_match(/Found 1 error/, output)
  end
end
  |