Code Duplication    Length = 6-6 lines in 2 locations

projects/packages/changelogger/tests/php/tests/lib/ChangelogTest.php 2 locations

@@ 93-98 (lines=6) @@
90
	/**
91
	 * Test setEntries error.
92
	 */
93
	public function testSetEntries_error1() {
94
		$changelog = new Changelog();
95
		$this->expectException( InvalidArgumentException::class );
96
		$this->expectExceptionMessage( 'Automattic\\Jetpack\\Changelog\\Changelog::setEntries: Expected a ChangelogEntry, got NULL at index 0' );
97
		$changelog->setEntries( array( null ) );
98
	}
99
100
	/**
101
	 * Test setEntries error.
@@ 103-108 (lines=6) @@
100
	/**
101
	 * Test setEntries error.
102
	 */
103
	public function testSetEntries_error2() {
104
		$changelog = new Changelog();
105
		$this->expectException( InvalidArgumentException::class );
106
		$this->expectExceptionMessage( 'Automattic\\Jetpack\\Changelog\\Changelog::setEntries: Expected a ChangelogEntry, got Automattic\\Jetpack\\Changelog\\Changelog at index 0' );
107
		$changelog->setEntries( array( $changelog ) );
108
	}
109
110
	/**
111
	 * Test JSON serialization.