aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Formula
diff options
context:
space:
mode:
authorJack Nagel2013-02-01 23:12:37 -0600
committerJack Nagel2013-02-01 23:38:52 -0600
commite5b92fe496d5b77bf841317dce302043c919056d (patch)
tree91ab930645bb30cf5aad3eab7a6da2ae2141a7cb /Library/Formula
parent6828bdeeff04b59e1a49ded6815fa7c2aafb0dac (diff)
downloadhomebrew-e5b92fe496d5b77bf841317dce302043c919056d.tar.bz2
graphviz: use test DSL
Diffstat (limited to 'Library/Formula')
-rw-r--r--Library/Formula/graphviz.rb18
1 files changed, 8 insertions, 10 deletions
diff --git a/Library/Formula/graphviz.rb b/Library/Formula/graphviz.rb
index 9c7aa081c..1f23ace7d 100644
--- a/Library/Formula/graphviz.rb
+++ b/Library/Formula/graphviz.rb
@@ -62,16 +62,14 @@ class Graphviz < Formula
(bin+'gvmap.sh').unlink
end
- def test
- mktemp do
- (Pathname.pwd+'sample.dot').write <<-EOS.undent
- digraph G {
- a -> b
- }
- EOS
-
- system "#{bin}/dot", "-Tpdf", "-o", "sample.pdf", "sample.dot"
- end
+ test do
+ (testpath/'sample.dot').write <<-EOS.undent
+ digraph G {
+ a -> b
+ }
+ EOS
+
+ system "#{bin}/dot", "-Tpdf", "-o", "sample.pdf", "sample.dot"
end
def caveats