mirror of
https://github.com/emilybache/GildedRose-Refactoring-Kata.git
synced 2026-10-14 18:15:41 +00:00
added a text based test for the java and python versions
This commit is contained in:
1 parent
53235864ec
commit
8da58f6dd1
11 files changed
+335
No files matched your search
Executable
+31
@@ -0,0 +1,31 @@
|
||||
|
||||
public class Main {
|
||||
public static void main(String[] args) {
|
||||
System.out.println("OMGHAI!");
|
||||
|
||||
Item[] items = new Item[] { new Item("+5 Dexterity Vest", 10, 20),
|
||||
new Item("Aged Brie", 2, 0),
|
||||
new Item("Elixir of the Mongoose", 5, 7),
|
||||
new Item("Sulfuras, Hand of Ragnaros", 0, 80),
|
||||
new Item("Backstage passes to a TAFKAL80ETC concert", 15, 20),
|
||||
new Item("Conjured Mana Cake", 3, 6) };
|
||||
|
||||
GildedRose app = new GildedRose(items);
|
||||
|
||||
int days = 2;
|
||||
if (args.length > 0) {
|
||||
days = Integer.parseInt(args[0]) + 1;
|
||||
}
|
||||
|
||||
for (int i = 0; i < days; i++) {
|
||||
System.out.println("-------- day " + i + " --------");
|
||||
System.out.println("name, sellIn, quality");
|
||||
for (Item item : items) {
|
||||
System.out.println(item);
|
||||
}
|
||||
System.out.println();
|
||||
app.updateQuality();
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
Reference in new issue
Block a user