Code Duplication    Length = 13-13 lines in 2 locations

tests/MyersDiffTest.php 2 locations

@@ 146-158 (lines=13) @@
143
	 *
144
	 * @return void
145
	 */
146
	public function testSingleDifferentTwo() {
147
		$algorithm = new MyersDiff;
148
		$x = array('a', 'b');
149
		$y = array('x', 'y');
150
		$diff = array(
151
			array('a', MyersDiff::DELETE),
152
			array('b', MyersDiff::DELETE),
153
			array('x', MyersDiff::INSERT),
154
			array('y', MyersDiff::INSERT),
155
		);
156
157
		$this->assertSame($diff, $algorithm->calculate($x, $y));
158
	}
159
160
	/**
161
	 * Test different strings containing three token.
@@ 212-224 (lines=13) @@
209
	 *
210
	 * void
211
	 */
212
	public function testDeleteBeforeInsert() {
213
		$algorithm = new MyersDiff;
214
		$x = array('a', 'b', 'c');
215
		$y = array('a', 'd', 'c');
216
		$diff = array(
217
			array('a', MyersDiff::KEEP),
218
			array('b', MyersDiff::DELETE),
219
			array('d', MyersDiff::INSERT),
220
			array('c', MyersDiff::KEEP),
221
		);
222
223
		$this->assertSame($diff, $algorithm->calculate($x, $y));
224
	}
225
}
226