void testEndsWithEmptyString() {
assertTrue( StringUtils.endsWith( new StringBuffer("12234545"), "") );
}
public void testEndsWithShorterString() {
assertTrue( StringUtils.endsWith( new StringBuffer("12345678"), "78"));
void testEndsWithNoMatch() {
assertFalse( StringUtils.endsWith( new StringBuffer("12345678"), "789"));
}
public void testEndsWithEmptyBuffer() {
assertFalse( StringUtils.endsWith( new StringBuffer(""), "12345667") );
Clone fragments detected by clone detection tool
File path: /apache-ant-1.7.0/src/tests/junit/org/apache/tools/ant/util/StringUtilsTest.java
|
|
File path: /apache-ant-1.7.0/src/tests/junit/org/apache/tools/ant/util/StringUtilsTest.java
|
Method name:
|
|
Method name:
|
Number of AST nodes: 0
|
|
Number of AST nodes: 0
|
|
1 | void testEndsWithEmptyString() {↵ | | 1 | void testEndsWithNoMatch() {↵
|
2 | assertTrue( StringUtils.endsWith( new StringBuffer("12234545"), "") );↵ | | 2 | assertFalse( StringUtils.endsWith( new StringBuffer("12345678"), "789"));↵
|
3 | }↵ | | 3 | }↵
|
|
4 | public void testEndsWithShorterString() {↵ | | 4 | public void testEndsWithEmptyBuffer() {↵
|
5 | assertTrue( StringUtils.endsWith( new StringBuffer("12345678"), "78"));↵ | | 5 | assertFalse( StringUtils.endsWith( new StringBuffer(""), "12345667") );↵
|
6 | | | 6 |
|
See real code fragment |
|
See real code fragment |
Summary
Number of common nesting structure subtrees | 0 |
Number of refactorable cases | 0 |
Number of non-refactorable cases | 0 |
Time elapsed for finding largest common nesting structure subtrees (ms) | 0.0 |
Clones location | |
Number of node comparisons | 0 |