diff options
| author | Ted Pennings | 2014-03-05 21:56:24 -0500 | 
|---|---|---|
| committer | Adam Vandenberg | 2014-03-05 19:40:44 -0800 | 
| commit | 61959549ef7d060e4bef9ed4d7c73eb249a45097 (patch) | |
| tree | cc954edb6e6a95d09eeda668e5c56724f1a62e4b | |
| parent | e9fb5f956ccf5088fe5117b028c85df1554b3a3b (diff) | |
| download | homebrew-61959549ef7d060e4bef9ed4d7c73eb249a45097.tar.bz2 | |
scala: add a test
Closes #27241.
Signed-off-by: Adam Vandenberg <flangy@gmail.com>
| -rw-r--r-- | Library/Formula/scala.rb | 14 | 
1 files changed, 14 insertions, 0 deletions
diff --git a/Library/Formula/scala.rb b/Library/Formula/scala.rb index 35ac248e0..b4718e1b8 100644 --- a/Library/Formula/scala.rb +++ b/Library/Formula/scala.rb @@ -54,4 +54,18 @@ class Scala < Formula        #{opt_prefix}/idea      EOS    end + +  test do +    file = testpath/'hello.scala' +    file.write <<-EOS.undent +      object Computer { +        def main(args: Array[String]) { +          println(2 + 2) +        } +      } +    EOS +    output = `'#{bin}/scala' #{file}` +    assert_equal "4", output.strip +    assert $?.success? +  end  end  | 
