Code Duplication    Length = 8-9 lines in 2 locations

packages/autoloader/tests/php/test_plugins_handler.php 2 locations

@@ 272-280 (lines=9) @@
269
	 *
270
	 * @covers Plugins_Handler::get_all_active_plugins
271
	 */
272
	public function test_get_all_active_plugins_single_file_plugin_skip() {
273
		$active_dir_plugin = array( 'test/test.php' );
274
		$active_plugins    = array_merge( $active_dir_plugin, array( 'single_file.php' ) );
275
		$this->set_up_mocks( $active_plugins );
276
277
		$expected_output = $active_dir_plugin;
278
		$actual_output   = $this->plugins_handler->get_all_active_plugins();
279
		$this->assertEquals( sort( $expected_output ), sort( $actual_output ) );
280
	}
281
282
	/**
283
	 * Tests get_all_active_plugins with a single-file plugin and single-file
@@ 288-295 (lines=8) @@
285
	 *
286
	 * @covers Plugins_Handler::get_all_active_plugins
287
	 */
288
	public function test_get_all_active_plugins_single_file_plugin_dont_skip() {
289
		$active_plugins = array( 'test/test.php', 'single_file.php' );
290
		$this->set_up_mocks( $active_plugins );
291
292
		$expected_output = $active_plugins;
293
		$actual_output   = $this->plugins_handler->get_all_active_plugins( false );
294
		$this->assertEquals( sort( $expected_output ), sort( $actual_output ) );
295
	}
296
297
	/**
298
	 * Tests get_all_active_plugins with activating plugins (via request and