mirror of
https://github.com/emilybache/GildedRose-Refactoring-Kata.git
synced 2026-02-15 14:31:28 +00:00
Revert "- Increase project information in README.md"
This reverts commit 6c7e1f4b06.
This commit is contained in:
parent
6c7e1f4b06
commit
58cf291e65
@ -2,28 +2,16 @@ package com.gildedrose;
|
||||
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
import java.util.stream.IntStream;
|
||||
|
||||
import static org.junit.jupiter.api.Assertions.assertEquals;
|
||||
|
||||
class GildedRoseTest {
|
||||
|
||||
@Test
|
||||
void dexterityVestShouldDecreaseSellInAndQualityEachUpdate() {
|
||||
String name = "+5 Dexterity Vest";
|
||||
int sellIn = 10;
|
||||
int quality = 20;
|
||||
int days = 2;
|
||||
|
||||
Item[] items = new Item[]{new Item(name, sellIn, quality)};
|
||||
void foo() {
|
||||
Item[] items = new Item[] { new Item("foo", 0, 0) };
|
||||
GildedRose app = new GildedRose(items);
|
||||
IntStream.rangeClosed(1, days).forEach(index -> {
|
||||
app.updateQuality();
|
||||
assertEquals(name, app.items[0].name);
|
||||
assertEquals(sellIn - index, app.items[0].sellIn);
|
||||
assertEquals(quality - index, app.items[0].quality);
|
||||
});
|
||||
app.updateQuality();
|
||||
assertEquals("fixme", app.items[0].name);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user