Add current vs expected
This commit is contained in:
parent
df3104b032
commit
bc3a37b65f
2 changed files with 12 additions and 5 deletions
|
@ -62,7 +62,7 @@ public class SearchResult {
|
|||
double res = 1;
|
||||
if (match) {
|
||||
res = ObjectType.getTypeWeight(match ? objectType : null);
|
||||
fullCompleteMatch = getSelfPhrase().equals(name);
|
||||
fullCompleteMatch = getSelfPhrase().equalsIgnoreCase(name);
|
||||
if (fullCompleteMatch) {
|
||||
res = res * 10;
|
||||
}
|
||||
|
|
|
@ -191,9 +191,16 @@ public class SearchUICoreTest {
|
|||
if (!Algorithms.stringsEqual(expected, present)) {
|
||||
System.out.println(String.format("Phrase: %s", phrase));
|
||||
System.out.println(String.format("Mismatch for '%s' != '%s'. Result: ", expected, present));
|
||||
}
|
||||
System.out.println("CURRENT RESULTS: ");
|
||||
for (SearchResult r : searchResults) {
|
||||
System.out.println(String.format("\t\"%s\",", formatResult(false, r, phrase)));
|
||||
|
||||
}
|
||||
System.out.println("EXPECTED : ");
|
||||
for (String r : result) {
|
||||
System.out.println(String.format("\t\"%s\",", r));
|
||||
|
||||
}
|
||||
}
|
||||
Assert.assertEquals(expected, present);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue