test/test_emaildiff.rb in diff-0.3.4.4 vs test/test_emaildiff.rb in diff-0.3.5
- old
+ new
@@ -6,19 +6,27 @@
require 'test_emailcases'
class EmailDiffTest < RUNIT::TestCase
include EmailDiffArrayTests
- def emailtest(a, b, c)
+ def emailtest(a, b, c, d = :tokens)
#puts "old string:"
#puts a
#puts "new string:"
#puts b
diff = EmailDiff.new(a, b)
- d = a.patch_email(diff,888,999)
+ #puts "old stripped:"
+ #puts diff.strip_a
+ #puts "new stripped:"
+ #puts diff.strip_b
+ if d == :tokens
+ result = a.patch_email(diff,888,999)
+ else
+ result = a.patch_email(diff)
+ end
#puts "result:"
#puts d
- assert_equal(c,d)
+ assert_equal(c,result)
end
end
RUNIT::CUI::TestRunner.run(EmailDiffTest.suite)