Skip to content

Commit

Permalink
Fix tests related to lowercase matching
Browse files Browse the repository at this point in the history
  • Loading branch information
stefan-kolb committed Apr 4, 2016
1 parent 2e14f84 commit 9e5219a
Show file tree
Hide file tree
Showing 4 changed files with 0 additions and 52 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -76,19 +76,6 @@ public void completeBeginnigOfKeyReturnsKey() {
Assert.assertEquals(Arrays.asList("testKey"), result);
}

@Test
public void completeLowercaseKeyReturnsKey() {
AutoCompletePreferences preferences = mock(AutoCompletePreferences.class);
BibtexKeyAutoCompleter autoCompleter = new BibtexKeyAutoCompleter(preferences);

BibEntry entry = new BibEntry();
entry.setField(BibEntry.KEY_FIELD, "testKey");
autoCompleter.addToIndex(entry);

List<String> result = autoCompleter.complete("testkey");
Assert.assertEquals(Arrays.asList("testKey"), result);
}

@Test
public void completeNullReturnsNothing() {
AutoCompletePreferences preferences = mock(AutoCompletePreferences.class);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -96,19 +96,6 @@ public void completeBeginnigOfValueReturnsValue() {
Assert.assertEquals(Arrays.asList("testValue"), result);
}

@Test
public void completeLowercaseValueReturnsValue() {
AutoCompletePreferences preferences = mock(AutoCompletePreferences.class);
DefaultAutoCompleter autoCompleter = new DefaultAutoCompleter("field", preferences);

BibEntry entry = new BibEntry();
entry.setField("field", "testValue");
autoCompleter.addToIndex(entry);

List<String> result = autoCompleter.complete("testvalue");
Assert.assertEquals(Arrays.asList("testValue"), result);
}

@Test
public void completeNullReturnsNothing() {
AutoCompletePreferences preferences = mock(AutoCompletePreferences.class);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -96,19 +96,6 @@ public void completeBeginnigOfValueReturnsValue() {
Assert.assertEquals(Arrays.asList("testValue"), result);
}

@Test
public void completeLowercaseValueReturnsValue() {
AutoCompletePreferences preferences = mock(AutoCompletePreferences.class);
EntireFieldAutoCompleter autoCompleter = new EntireFieldAutoCompleter("field", preferences);

BibEntry entry = new BibEntry();
entry.setField("field", "testValue");
autoCompleter.addToIndex(entry);

List<String> result = autoCompleter.complete("testvalue");
Assert.assertEquals(Arrays.asList("testValue"), result);
}

@Test
public void completeNullReturnsNothing() {
AutoCompletePreferences preferences = mock(AutoCompletePreferences.class);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -96,19 +96,6 @@ public void completeBeginnigOfNameReturnsName() {
Assert.assertEquals(Arrays.asList("Testname"), result);
}

@Test
public void completeLowercaseNameReturnsName() {
AutoCompletePreferences preferences = mock(AutoCompletePreferences.class);
NameFieldAutoCompleter autoCompleter = new NameFieldAutoCompleter("field", preferences);

BibEntry entry = new BibEntry();
entry.setField("field", "Testname");
autoCompleter.addToIndex(entry);

List<String> result = autoCompleter.complete("test");
Assert.assertEquals(Arrays.asList("Testname"), result);
}

@Test
public void completeNullReturnsNothing() {
AutoCompletePreferences preferences = mock(AutoCompletePreferences.class);
Expand Down

0 comments on commit 9e5219a

Please sign in to comment.