Add test for Upper (#3001)
This commit is contained in:
parent
1b02b41fcc
commit
140f6ec6e3
17
src/test/java/com/thealgorithms/strings/UpperTest.java
Normal file
17
src/test/java/com/thealgorithms/strings/UpperTest.java
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
package com.thealgorithms.strings;
|
||||||
|
|
||||||
|
import org.junit.jupiter.api.Test;
|
||||||
|
|
||||||
|
import static org.junit.jupiter.api.Assertions.*;
|
||||||
|
|
||||||
|
public class UpperTest {
|
||||||
|
@Test
|
||||||
|
public void toUpperCase() {
|
||||||
|
String input1 = "hello world";
|
||||||
|
String input2 = "hElLo WoRlD";
|
||||||
|
String input3 = "HELLO WORLD";
|
||||||
|
assertEquals("HELLO WORLD", Upper.toUpperCase(input1));
|
||||||
|
assertEquals("HELLO WORLD", Upper.toUpperCase(input2));
|
||||||
|
assertEquals("HELLO WORLD", Upper.toUpperCase(input3));
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user