homebrew-core/Formula/vert.x.rb
Clement Escoffier c2f48cd0eb
vert.x 3.7.0
Closes #38572.

Signed-off-by: Chongyu Zhu <i@lembacon.com>
2019-04-01 21:31:57 +08:00

30 lines
891 B
Ruby

class VertX < Formula
desc "Toolkit for building reactive applications on the JVM"
homepage "https://vertx.io/"
url "https://bintray.com/vertx/downloads/download_file?file_path=vert.x-3.7.0-full.tar.gz"
sha256 "2a664b214f7be40d38c823d936a48474f7f0b4901bbd5c2c0e7e173676235b1c"
bottle :unneeded
depends_on :java => "1.8+"
def install
rm_f Dir["bin/*.bat"]
libexec.install %w[bin conf lib]
bin.install_symlink "#{libexec}/bin/vertx"
end
test do
(testpath/"HelloWorld.java").write <<~EOS
import io.vertx.core.AbstractVerticle;
public class HelloWorld extends AbstractVerticle {
public void start() {
System.out.println("Hello World!");
vertx.close();
System.exit(0);
}
}
EOS
output = shell_output("#{bin}/vertx run HelloWorld.java")
assert_equal "Hello World!\n", output
end
end