Smarticles101 před 9 roky
rodič
revize
851f61e0a9

+ 2
- 2
exercises/kindergarten-garden/src/example/java/KindergartenGarden.java Zobrazit soubor

7
     private String[] students;
7
     private String[] students;
8
     private String garden;
8
     private String garden;
9
     private final int PLANTS_PER_STUDENT_PER_ROW = 2;
9
     private final int PLANTS_PER_STUDENT_PER_ROW = 2;
10
-    private int NEW_ROW_LOCATION;
10
+    private final nt NEW_ROW_LOCATION;
11
 
11
 
12
     private final static String[] DEFAULT_STUDENTS = {
12
     private final static String[] DEFAULT_STUDENTS = {
13
             "Alice", "Bob", "Charlie", "David",
13
             "Alice", "Bob", "Charlie", "David",
41
 
41
 
42
         return plants.toArray(new Plant[0]);
42
         return plants.toArray(new Plant[0]);
43
     }
43
     }
44
-}
44
+}

+ 4
- 4
exercises/kindergarten-garden/src/test/java/KindergartenGardenTest.java Zobrazit soubor

112
         Plant[] expected = {Plant.VIOLETS, Plant.CLOVER, Plant.RADISHES, Plant.VIOLETS};
112
         Plant[] expected = {Plant.VIOLETS, Plant.CLOVER, Plant.RADISHES, Plant.VIOLETS};
113
 
113
 
114
         assertEquals(expected,
114
         assertEquals(expected,
115
-                new KindergartenGarden(plants).getPlantsOfStudent(student));
115
+                new KindergartenGarden(plants, studentArray).getPlantsOfStudent(student));
116
     }
116
     }
117
 
117
 
118
     @Ignore("Remove to run test")
118
     @Ignore("Remove to run test")
124
         Plant[] expected = {Plant.RADISHES, Plant.RADISHES, Plant.GRASS, Plant.CLOVER};
124
         Plant[] expected = {Plant.RADISHES, Plant.RADISHES, Plant.GRASS, Plant.CLOVER};
125
 
125
 
126
         assertEquals(expected,
126
         assertEquals(expected,
127
-                new KindergartenGarden(plants).getPlantsOfStudent(student));
127
+                new KindergartenGarden(plants, studentArray).getPlantsOfStudent(student));
128
     }
128
     }
129
 
129
 
130
     @Ignore("Remove to run test")
130
     @Ignore("Remove to run test")
136
         Plant[] expected = {Plant.GRASS, Plant.VIOLETS, Plant.CLOVER, Plant.GRASS};
136
         Plant[] expected = {Plant.GRASS, Plant.VIOLETS, Plant.CLOVER, Plant.GRASS};
137
 
137
 
138
         assertEquals(expected,
138
         assertEquals(expected,
139
-                new KindergartenGarden(plants).getPlantsOfStudent(student));
139
+                new KindergartenGarden(plants, studentArray).getPlantsOfStudent(student));
140
     }
140
     }
141
 
141
 
142
     @Ignore("Remove to run test")
142
     @Ignore("Remove to run test")
148
         Plant[] expected = {Plant.RADISHES, Plant.GRASS, Plant.CLOVER, Plant.VIOLETS};
148
         Plant[] expected = {Plant.RADISHES, Plant.GRASS, Plant.CLOVER, Plant.VIOLETS};
149
 
149
 
150
         assertEquals(expected,
150
         assertEquals(expected,
151
-                new KindergartenGarden(plants).getPlantsOfStudent(student));
151
+                new KindergartenGarden(plants, studentArray).getPlantsOfStudent(student));
152
     }
152
     }
153
 }
153
 }