|
@@ -244,6 +244,24 @@ public class InventoryTest {
|
244
|
244
|
Assert.assertEquals(expected, actual);
|
245
|
245
|
}
|
246
|
246
|
|
|
247
|
+ @Test
|
|
248
|
+ public void ConjuredQualityTest(){
|
|
249
|
+ //Given
|
|
250
|
+ Item conjured = new Item("Conjured", 10, 20);
|
|
251
|
+ Item[] itemArr = new Item[1];
|
|
252
|
+ itemArr[0] = conjured;
|
|
253
|
+ Inventory newInv = new Inventory(itemArr);
|
|
254
|
+ int expected = 18;
|
|
255
|
+
|
|
256
|
+ //When
|
|
257
|
+ newInv.updateSellIn();
|
|
258
|
+ newInv.updateQuality();
|
|
259
|
+
|
|
260
|
+ //Then
|
|
261
|
+ int actual = conjured.getQuality();
|
|
262
|
+
|
|
263
|
+ Assert.assertEquals(expected, actual);
|
|
264
|
+ }
|
247
|
265
|
}
|
248
|
266
|
|
249
|
267
|
/*
|