add new lines before assert statements

This commit is contained in:
danielmcnally285 2024-03-16 12:34:35 +00:00
parent 82ca2b8b92
commit 96450ee79d
1 changed files with 4 additions and 0 deletions

View File

@ -22,12 +22,14 @@ public class LastNCharactersUnitTest {
.skip(s.length() - n)
.map(String::valueOf)
.collect(Collectors.joining());
assertThat(result).isEqualTo("2024");
}
@Test
void givenString_whenUsingOneArgSubstringMethod_thenObtainLastNCharacters() {
int beginIndex = s.length() - n;
assertThat(s.substring(beginIndex)).isEqualTo("2024");
}
@ -37,6 +39,7 @@ public class LastNCharactersUnitTest {
.skip(s.length() - n)
.map(String::valueOf)
.collect(Collectors.joining());
assertThat(result).isEqualTo("2024");
}
@ -49,6 +52,7 @@ public class LastNCharactersUnitTest {
void givenString_whenUsingTwoArgSubstringMethod_thenObtainLastNCharacters() {
int beginIndex = s.length() - n;
String result = s.substring(beginIndex, s.length());
assertThat(result).isEqualTo("2024");
}