void expectDebuglog(String target, String log) { executeTarget(target); String realLog = getFullLog(); assertEquals(log, realLog); } /** * Assert that the given substring is in the log messages. */ public void assertDebuglogContaining(String substring) { String realLog = getFullLog(); assertTrue("expecting debug log to contain \"" + substring + "\" log was \"" + realLog + "\"", realLog.indexOf(substring) >= 0);
void expectLog(String target, String log) { executeTarget(target); String realLog = getLog(); assertEquals(log, realLog); } /** * Assert that the given substring is in the log messages. */ public void assertLogContaining(String substring) { String realLog = getLog(); assertTrue("expecting log to contain \"" + substring + "\" log was \"" + realLog + "\"", realLog.indexOf(substring) >= 0);
Clone fragments detected by clone detection tool
File path: /apache-ant-1.7.0/src/tests/junit/org/apache/tools/ant/BuildFileTest.java File path: /apache-ant-1.7.0/src/tests/junit/org/apache/tools/ant/BuildFileTest.java
Method name: Method name:
Number of AST nodes: 0 Number of AST nodes: 0
1
void expectDebuglog(String target, String log) {
1
void expectLog(String target, String log) {
2
        executeTarget(target);
2
        executeTarget(target);
3
        String realLog = getFullLog();
3
        String realLog = getLog();
4
        assertEquals(log, realLog);
4
        assertEquals(log, realLog);
5
    }
5
    }
6
    /**
6
    /**
7
     * Assert that the given substring is in the log messages.
7
     * Assert that the given substring is in the log messages.
8
     */
8
     */
9
    public void assertDebuglogContaining(String substring) {
9
    public void assertLogContaining(String substring) {
10
        String realLog = getFullLog();
10
        String realLog = getLog();
11
        assertTrue("expecting debug log to contain \"" + substring 
11
        assertTrue("expecting log to contain \"" + substring 
12
                   + "\" log was \""
12
+ "\" log was \""
13
                   + realLog + "\"",
13
                   + realLog + "\"",
14
                   realLog.indexOf(substring) >= 0);
14
                   realLog.indexOf(substring) >= 0);
15
    
15
    
Summary
Number of common nesting structure subtrees0
Number of refactorable cases0
Number of non-refactorable cases0
Time elapsed for finding largest common nesting structure subtrees (ms)0.0
Clones location
Number of node comparisons0