Sha256: 45966990fcb53b15f2b1abc5e0e53bee5e7540ccc16cd564bb10f946202a8084

Contents?: true

Size: 1009 Bytes

Versions: 2

Compression:

Stored size: 1009 Bytes

Contents

require 'helper'

class BasicGeneratorTest < MiniTest::Unit::TestCase

  def test_generated_html
    diff = new_diff(fixture('first.diff'), :generator => PrettyDiff::BasicGenerator)
    assert_equal fixture('first.diff.html'), diff.to_html
  end

  def test_more_generated_html
    diff = new_diff(fixture('text.diff'), :generator => PrettyDiff::BasicGenerator)
    assert_equal fixture('text.diff.html'), diff.to_html
  end

  def test_another_generated_html
    diff = new_diff(fixture('csharp.diff'), :generator => PrettyDiff::BasicGenerator)
    assert_equal fixture('csharp.diff.html'), diff.to_html
  end

  def test_generate_html_for_blank
    diff = new_diff(fixture('blank.diff'), :generator => PrettyDiff::BasicGenerator)
    assert_equal fixture('blank.diff.html'), diff.to_html
  end

  def test_generate_html_for_single_line_diffs
    diff = new_diff(fixture('single_line.diff'), :generator => PrettyDiff::BasicGenerator)
    assert_equal fixture('single_line.diff.html'), diff.to_html
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
pretty_diff-2.0.1 test/basic_generator_test.rb
pretty_diff-2.0.0 test/basic_generator_test.rb