File path: /apache-ant-1.7.0/src/tests/junit/org/apache/tools/ant/AntClassLoaderTest.java | File path: /apache-ant-1.7.0/src/tests/junit/org/apache/tools/ant/AntClassLoaderTest.java | |||
Method name: void testJarWithManifestInNonAsciiDir()
|
Method name: void testJarWithManifestInDirWithSpace()
|
|||
Number of AST nodes: 8 | Number of AST nodes: 8 | |||
1 | String mainjarstring = getProject().getProperty("main.jar.nonascii");↵ | 1 | String mainjarstring = getProject().getProperty("main.jar");↵ | |
2 | String extjarstring = getProject().getProperty("ext.jar.nonascii");↵ | 2 | String extjarstring = getProject().getProperty("ext.jar");↵ | |
3 | Path myPath = new Path(getProject());↵ | 3 | Path myPath = new Path(getProject());↵ | |
4 | myPath.setLocation(new File(mainjarstring));↵ | 4 | myPath.setLocation(new File(mainjarstring));↵ | |
5 | getProject().setUserProperty("build.sysclasspath","ignore");↵ | 5 | getProject().setUserProperty("build.sysclasspath","ignore");↵ | |
6 | AntClassLoader myLoader = getProject().createClassLoader(myPath);↵ | 6 | AntClassLoader myLoader = getProject().createClassLoader(myPath);↵ | |
7 | String path = myLoader.getClasspath();↵ | 7 | String path = myLoader.getClasspath();↵ | |
8 | assertEquals(mainjarstring + File.pathSeparator + extjarstring, path); | 8 |
| |
See real code fragment | See real code fragment |
Number of common nesting structure subtrees | 1 |
Number of refactorable cases | 1 |
Number of non-refactorable cases | 0 |
Time elapsed for finding largest common nesting structure subtrees (ms) | 0.0 |
Clones location | Clones are declared in the same class |
Number of node comparisons | 40 |
Number of mapped statements | 8 |
Number of unmapped statements in the first code fragment | 0 |
Number of unmapped statements in the second code fragment | 0 |
Time elapsed for statement mapping (ms) | 0.0 |
Clone type | Type 2 |
ID | Statement | ID | Statement | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
1 | String mainjarstring = getProject().getProperty("main.jar.nonascii"); |
| 1 | String mainjarstring = getProject().getProperty("main.jar"); | ||||||||||
2 | String extjarstring = getProject().getProperty("ext.jar.nonascii"); |
| 2 | String extjarstring = getProject().getProperty("ext.jar"); | ||||||||||
3 | Path myPath = new Path(getProject()); | 3 | Path myPath = new Path(getProject()); | |||||||||||
4 | myPath.setLocation(new File(mainjarstring)); | 4 | myPath.setLocation(new File(mainjarstring)); | |||||||||||
5 | getProject().setUserProperty("build.sysclasspath", "ignore"); | 5 | getProject().setUserProperty("build.sysclasspath", "ignore"); | |||||||||||
6 | AntClassLoader myLoader = getProject().createClassLoader(myPath); | 6 | AntClassLoader myLoader = getProject().createClassLoader(myPath); | |||||||||||
7 | String path = myLoader.getClasspath(); | 7 | String path = myLoader.getClasspath(); | |||||||||||
8 | assertEquals(mainjarstring + File.pathSeparator + extjarstring, path); | 8 | assertEquals(mainjarstring + File.pathSeparator + extjarstring, path); |
Row | Violation |
---|