BAEL-6334 Improve test names and typos

This commit is contained in:
Sam Gardner 2023-05-18 10:27:08 +01:00
parent 956660497a
commit ae1a3f9e79
1 changed files with 4 additions and 4 deletions

View File

@ -20,7 +20,7 @@ public class ListContainsElementFromOtherListTest {
final private List<String> listOfCities = Arrays.asList("London", "Berlin", "Paris", "Brussels"); final private List<String> listOfCities = Arrays.asList("London", "Berlin", "Paris", "Brussels");
@Test @Test
public void givenWholeValuesToCompare_whenUsingCollectionsDisjoint_thenDetectElementsInTwoLists() { public void givenValuesToCompare_whenUsingCollectionsDisjoint_thenDetectElementsInTwoLists() {
boolean shouldBeTrue = !Collections.disjoint(listOfLetters, listOfLettersWithOverlap); boolean shouldBeTrue = !Collections.disjoint(listOfLetters, listOfLettersWithOverlap);
assertTrue(shouldBeTrue); assertTrue(shouldBeTrue);
@ -29,7 +29,7 @@ public class ListContainsElementFromOtherListTest {
} }
@Test @Test
public void givenWholeValuesToCompare_whenUsingStreams_thenDetectElementsInTwoLists() { public void givenValuesToCompare_whenUsingStreams_thenDetectElementsInTwoLists() {
boolean shouldBeTrue = listOfLetters.stream() boolean shouldBeTrue = listOfLetters.stream()
.anyMatch(listOfLettersWithOverlap::contains); .anyMatch(listOfLettersWithOverlap::contains);
assertTrue(shouldBeTrue); assertTrue(shouldBeTrue);
@ -40,7 +40,7 @@ public class ListContainsElementFromOtherListTest {
} }
@Test @Test
public void givenWholeValuesToCompare_whenUsingApacheCollectionUtils_thenDetectElementsInTwoLists() { public void givenValuesToCompare_whenUsingApacheCollectionUtils_thenDetectElementsInTwoLists() {
boolean shouldBeTrue = CollectionUtils.containsAny(listOfLetters, listOfLettersWithOverlap); boolean shouldBeTrue = CollectionUtils.containsAny(listOfLetters, listOfLettersWithOverlap);
assertTrue(shouldBeTrue); assertTrue(shouldBeTrue);
@ -49,7 +49,7 @@ public class ListContainsElementFromOtherListTest {
} }
@Test @Test
public void givenWholePorpertiesInObjectsToCompare_whenUsingStreams_thenDetectElementsInTwoLists() { public void givenPropertiesInObjectsToCompare_whenUsingStreams_thenDetectElementsInTwoLists() {
Country france = new Country("France", "Paris"); Country france = new Country("France", "Paris");
Country belgium = new Country("Belgium", "Brussels"); Country belgium = new Country("Belgium", "Brussels");
Country spain = new Country("Spain", "Madrid"); Country spain = new Country("Spain", "Madrid");