free_mutant/spec/integration/mutant/differ_spec.rb
2012-08-16 18:02:03 +02:00

15 lines
300 B
Ruby

require 'spec_helper'
describe Mutant,'differ' do
specify 'allows to create diffs from text' do
a = "Foo\nBar\n"
b = "Foo\nBaz\n"
differ = Mutant::Differ.new(a,b)
differ.diff.should == strip_indent(<<-RUBY)
@@ -1,3 +1,3 @@
Foo
-Bar
+Baz
RUBY
end
end