Skip to content

Commit

Permalink
Quiet down the test failure output a little
Browse files Browse the repository at this point in the history
  • Loading branch information
tekkub authored and defunkt committed Mar 25, 2010
1 parent bf7155e commit 60a36e1
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions test/markup_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,16 @@ class MarkupTest < Test::Unit::TestCase
markup = readme.split('/').last.gsub(/^README\./, '')

define_method "test_#{markup}" do
source = File.read(readme)

expected_file = "#{readme}.html"
expected = File.read(expected_file)
actual = GitHub::Markup.render(readme, File.read(readme))

if source != expected
assert(source != actual, "#{markup} did not render anything")
end

diff = IO.popen("diff -u - #{expected_file}", 'r+') do |f|
f.write actual
f.close_write
Expand Down

0 comments on commit 60a36e1

Please sign in to comment.