Code Duplication    Length = 8-8 lines in 3 locations

packages/autoloader/tests/php/tests/unit/test-path-processor.php 3 locations

@@ 106-113 (lines=8) @@
103
	/**
104
	 * Tests that find_directory_with_autoloader finds directories for plugins that have the autoloader.
105
	 */
106
	public function test_finds_directory_for_autoloaded_plugin() {
107
		$path = $this->processor->find_directory_with_autoloader(
108
			'dummy_current/dummy_current.php',
109
			array( TEST_DATA_PATH . '/plugins' )
110
		);
111
112
		$this->assertEquals( TEST_DATA_PATH . '/plugins/dummy_current', $path );
113
	}
114
115
	/**
116
	 * Tests that find_directory_with_autoloader finds directories using Windows paths.
@@ 118-125 (lines=8) @@
115
	/**
116
	 * Tests that find_directory_with_autoloader finds directories using Windows paths.
117
	 */
118
	public function test_finds_directory_for_autoloaded_plugin_with_windows_paths() {
119
		$path = $this->processor->find_directory_with_autoloader(
120
			'dummy_current\dummy_current.php',
121
			array( WP_PLUGIN_DIR )
122
		);
123
124
		$this->assertEquals( TEST_DATA_PATH . '/plugins/dummy_current', $path );
125
	}
126
127
	/**
128
	 * Tests that find_directory_with_autoloader finds the realpath of directories that use symlinks.
@@ 130-137 (lines=8) @@
127
	/**
128
	 * Tests that find_directory_with_autoloader finds the realpath of directories that use symlinks.
129
	 */
130
	public function test_finds_directory_realpath_for_symlinked_plugin() {
131
		$path = $this->processor->find_directory_with_autoloader(
132
			'dummy_symlink\dummy_current.php',
133
			array( WP_PLUGIN_DIR )
134
		);
135
136
		$this->assertEquals( TEST_DATA_PATH . '/plugins/dummy_current', $path );
137
	}
138
}
139