瀏覽代碼

fix the Randall discovery

Kristofer Younger 6 年之前
父節點
當前提交
0b5546841f
共有 1 個檔案被更改,包括 13 行新增0 行删除
  1. 13
    0
      StringUtilitiesTest.java

+ 13
- 0
StringUtilitiesTest.java 查看文件

@@ -26,6 +26,19 @@ public class StringUtilitiesTest {
26 26
     }
27 27
     
28 28
     @Test
29
+    public void testGetMiddleCharacter_ForOddWord(){
30
+        //Given
31
+        String word = "disinformations";
32
+        char expected = 'r';
33
+        
34
+        //When
35
+        char actual = utilities.getMiddleCharacter(word);
36
+        
37
+        //Then
38
+        assertEquals(expected, actual);
39
+    }
40
+    
41
+    @Test
29 42
     public void testGetMiddleCharacter_ForEvenWord(){
30 43
         //Given
31 44
         String word = "dogs";