checkstyle: use test DSL
This commit is contained in:
parent
8818e4d3f7
commit
3ca0b415a6
1 changed files with 4 additions and 7 deletions
|
@ -10,15 +10,12 @@ class Checkstyle < Formula
|
|||
bin.write_jar_script libexec/'checkstyle-5.6-all.jar', 'checkstyle'
|
||||
end
|
||||
|
||||
def test
|
||||
test do
|
||||
# Note this test "fails" because the audit has issues
|
||||
# TODO - pipe through cat to ingore error code
|
||||
mktemp do
|
||||
# create test file
|
||||
(Pathname.pwd/"Test.java").write <<-EOS.undent
|
||||
(testpath/"Test.java").write <<-EOS.undent
|
||||
public class Test{ }
|
||||
EOS
|
||||
system "#{bin}/checkstyle", "-c", "#{libexec}/sun_checks.xml", "-r", "Test.java"
|
||||
end
|
||||
EOS
|
||||
system "#{bin}/checkstyle", "-c", "#{libexec}/sun_checks.xml", "-r", "Test.java"
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue