mirror of
https://github.com/emilybache/GildedRose-Refactoring-Kata.git
synced 2026-02-15 06:21:29 +00:00
fixed overdue test
This commit is contained in:
parent
bb1aafe64d
commit
b41fa5cc4d
@ -30,8 +30,8 @@ class GildedRoseTest {
|
|||||||
|
|
||||||
@Feature("Once the sell by date has passed, Quality degrades twice as fast")
|
@Feature("Once the sell by date has passed, Quality degrades twice as fast")
|
||||||
@ParameterizedTest(name = "sellIn: {arguments}")
|
@ParameterizedTest(name = "sellIn: {arguments}")
|
||||||
@ValueSource(ints = {0, 1})
|
@ValueSource(ints = {0, -1, -2})
|
||||||
void shouldTheDegradeQualityFasterOnceSellDateIsPassed(int sellIn) {
|
void shouldDegradeQualityTwiceFastOnceSellDateIsPassed(int sellIn) {
|
||||||
// given
|
// given
|
||||||
val initialQuality = nextInt(3, 50);
|
val initialQuality = nextInt(3, 50);
|
||||||
GildedRose app = prepareApp(new Item("foo", sellIn, initialQuality));
|
GildedRose app = prepareApp(new Item("foo", sellIn, initialQuality));
|
||||||
@ -41,7 +41,7 @@ class GildedRoseTest {
|
|||||||
|
|
||||||
// then
|
// then
|
||||||
final Item item = app.items[0];
|
final Item item = app.items[0];
|
||||||
assertItem(item, "foo", -2, initialQuality - 2);
|
assertItem(item, "foo", sellIn - 1, initialQuality - 2);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Feature("\"Sulfuras\", being a legendary item, never has to be sold or decreases in Quality")
|
@Feature("\"Sulfuras\", being a legendary item, never has to be sold or decreases in Quality")
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user