aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Formula
diff options
context:
space:
mode:
authorHannu Hartikainen2014-04-01 18:07:05 +0300
committerMike McQuaid2014-04-01 10:33:51 -0500
commit29d9da77851d18655a5e97d588eebaf0c3d6a0a3 (patch)
treec162894c9a8e82b925609039ea6693f8fd98d86f /Library/Formula
parent78a86d4e3961bec300ae819083a74f3dfd7152e7 (diff)
downloadhomebrew-29d9da77851d18655a5e97d588eebaf0c3d6a0a3.tar.bz2
elinks: add a test (renders a simple page)
Diffstat (limited to 'Library/Formula')
-rw-r--r--Library/Formula/elinks.rb10
1 files changed, 10 insertions, 0 deletions
diff --git a/Library/Formula/elinks.rb b/Library/Formula/elinks.rb
index 6f56e3d3a..3c6a5becc 100644
--- a/Library/Formula/elinks.rb
+++ b/Library/Formula/elinks.rb
@@ -27,4 +27,14 @@ class Elinks < Formula
"--enable-256-colors"
system "make install"
end
+
+ test do
+ (testpath/"test.html").write <<-EOS.undent
+ <!DOCTYPE html>
+ <title>elinks test</title>
+ Hello world!
+ <ol><li>one</li><li>two</li></ol>
+ EOS
+ assert_match /^\s*Hello world!\n+ *1. one\n *2. two\s*$/, `elinks test.html`
+ end
end