mirror of
https://github.com/emilybache/GildedRose-Refactoring-Kata.git
synced 2026-10-13 17:49:25 +00:00
changed activity syntax: -foo -> :foo;
This commit is contained in:
1 parent
ff06861ab7
commit
749d8f5ff5
8 files changed
+39
-40
No files matched your search
@@ -9,25 +9,25 @@ end note
|
|||||||
if (not "Aged Brie" and not "Backstage passes to a TAFKAL80ETC concert") then (yes)
|
if (not "Aged Brie" and not "Backstage passes to a TAFKAL80ETC concert") then (yes)
|
||||||
if (quality > 0) then (yes)
|
if (quality > 0) then (yes)
|
||||||
if (not "Sulfuras, Hand of Ragnaros") then (yes)
|
if (not "Sulfuras, Hand of Ragnaros") then (yes)
|
||||||
-lower quality with 1
|
:lower quality with 1;
|
||||||
else (no)
|
else (no)
|
||||||
endif
|
endif
|
||||||
else (no)
|
else (no)
|
||||||
endif
|
endif
|
||||||
else (no)
|
else (no)
|
||||||
if (quality < 50) then (yes)
|
if (quality < 50) then (yes)
|
||||||
-increase quality with 1
|
:increase quality with 1;
|
||||||
if ("Backstage passes to a TAFKAL80ETC concert") then (yes)
|
if ("Backstage passes to a TAFKAL80ETC concert") then (yes)
|
||||||
if (sell in < 11) then (yes)
|
if (sell in < 11) then (yes)
|
||||||
if (quality < 50) then (yes)
|
if (quality < 50) then (yes)
|
||||||
-increase quality with 1
|
:increase quality with 1;
|
||||||
else (no)
|
else (no)
|
||||||
endif
|
endif
|
||||||
else (no)
|
else (no)
|
||||||
endif
|
endif
|
||||||
if (sell in < 6) then (yes)
|
if (sell in < 6) then (yes)
|
||||||
if (quality < 50) then (yes)
|
if (quality < 50) then (yes)
|
||||||
-increase quality with 1
|
:increase quality with 1;
|
||||||
else (no)
|
else (no)
|
||||||
endif
|
endif
|
||||||
else (no)
|
else (no)
|
||||||
@@ -39,7 +39,7 @@ else (no)
|
|||||||
endif
|
endif
|
||||||
|
|
||||||
if (not "Sulfuras, Hand of Ragnaros") then (yes)
|
if (not "Sulfuras, Hand of Ragnaros") then (yes)
|
||||||
-lower sell in with 1
|
:lower sell in with 1;
|
||||||
else (no)
|
else (no)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
@@ -48,17 +48,17 @@ if (sell in < 0) then (yes)
|
|||||||
if (not "Backstage passes to a TAFKAL80ETC concert") then (yes)
|
if (not "Backstage passes to a TAFKAL80ETC concert") then (yes)
|
||||||
if (quality > 0) then (yes)
|
if (quality > 0) then (yes)
|
||||||
if (not "Sulfuras, Hand of Ragnaros") then (yes)
|
if (not "Sulfuras, Hand of Ragnaros") then (yes)
|
||||||
-lower quality with 1
|
:lower quality with 1;
|
||||||
else (no)
|
else (no)
|
||||||
endif
|
endif
|
||||||
else (no)
|
else (no)
|
||||||
endif
|
endif
|
||||||
else (no)
|
else (no)
|
||||||
-lower quality with quality
|
:lower quality with quality;
|
||||||
endif
|
endif
|
||||||
else (no)
|
else (no)
|
||||||
if (quality < 50) then (yes)
|
if (quality < 50) then (yes)
|
||||||
-increase quality with 1
|
:increase quality with 1;
|
||||||
else (no)
|
else (no)
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
|
|||||||
@@ -6,9 +6,8 @@ note left
|
|||||||
An item has a name, a sell in value and a quality value
|
An item has a name, a sell in value and a quality value
|
||||||
end note
|
end note
|
||||||
|
|
||||||
-lower quality with 1
|
:lower quality with 1;
|
||||||
|
:lower sell in with 1;
|
||||||
-lower sell in with 1
|
|
||||||
|
|
||||||
stop
|
stop
|
||||||
|
|
||||||
|
|||||||
@@ -6,11 +6,11 @@ note left
|
|||||||
An item has a name, a sell in value and a quality value
|
An item has a name, a sell in value and a quality value
|
||||||
end note
|
end note
|
||||||
|
|
||||||
-lower quality with 1
|
:lower quality with 1;
|
||||||
-lower sell in with 1
|
:lower sell in with 1;
|
||||||
|
|
||||||
if (sell in < 0) then (yes)
|
if (sell in < 0) then (yes)
|
||||||
-lower quality with 1
|
:lower quality with 1;
|
||||||
else (no)
|
else (no)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
|||||||
@@ -7,15 +7,15 @@ note left
|
|||||||
end note
|
end note
|
||||||
|
|
||||||
if (quality > 0) then (yes)
|
if (quality > 0) then (yes)
|
||||||
-lower quality with 1
|
:lower quality with 1;
|
||||||
else (no)
|
else (no)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
-lower sell in with 1
|
:lower sell in with 1;
|
||||||
|
|
||||||
if (sell in < 0) then (yes)
|
if (sell in < 0) then (yes)
|
||||||
if (quality > 0) then (yes)
|
if (quality > 0) then (yes)
|
||||||
-lower quality with 1
|
:lower quality with 1;
|
||||||
else (no)
|
else (no)
|
||||||
endif
|
endif
|
||||||
else (no)
|
else (no)
|
||||||
|
|||||||
@@ -8,23 +8,23 @@ end note
|
|||||||
|
|
||||||
if (not "Aged Brie") then (yes)
|
if (not "Aged Brie") then (yes)
|
||||||
if (quality > 0) then (yes)
|
if (quality > 0) then (yes)
|
||||||
-lower quality with 1
|
:lower quality with 1;
|
||||||
else (no)
|
else (no)
|
||||||
endif
|
endif
|
||||||
else (no)
|
else (no)
|
||||||
-increase quality with 1
|
:increase quality with 1;
|
||||||
endif
|
endif
|
||||||
|
|
||||||
-lower sell in with 1
|
:lower sell in with 1;
|
||||||
|
|
||||||
if (sell in < 0) then (yes)
|
if (sell in < 0) then (yes)
|
||||||
if (not "Aged Brie") then (yes)
|
if (not "Aged Brie") then (yes)
|
||||||
if (quality > 0) then (yes)
|
if (quality > 0) then (yes)
|
||||||
-lower quality with 1
|
:lower quality with 1;
|
||||||
else (no)
|
else (no)
|
||||||
endif
|
endif
|
||||||
else (no)
|
else (no)
|
||||||
-increase quality with 1
|
:increase quality with 1;
|
||||||
endif
|
endif
|
||||||
else (no)
|
else (no)
|
||||||
endif
|
endif
|
||||||
|
|||||||
@@ -8,27 +8,27 @@ end note
|
|||||||
|
|
||||||
if (not "Aged Brie") then (yes)
|
if (not "Aged Brie") then (yes)
|
||||||
if (quality > 0) then (yes)
|
if (quality > 0) then (yes)
|
||||||
-lower quality with 1
|
:lower quality with 1;
|
||||||
else (no)
|
else (no)
|
||||||
endif
|
endif
|
||||||
else (no)
|
else (no)
|
||||||
if (quality < 50) then (yes)
|
if (quality < 50) then (yes)
|
||||||
-increase quality with 1
|
:increase quality with 1;
|
||||||
else (no)
|
else (no)
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
|
|
||||||
-lower sell in with 1
|
:lower sell in with 1;
|
||||||
|
|
||||||
if (sell in < 0) then (yes)
|
if (sell in < 0) then (yes)
|
||||||
if (not "Aged Brie") then (yes)
|
if (not "Aged Brie") then (yes)
|
||||||
if (quality > 0) then (yes)
|
if (quality > 0) then (yes)
|
||||||
-lower quality with 1
|
:lower quality with 1;
|
||||||
else (no)
|
else (no)
|
||||||
endif
|
endif
|
||||||
else (no)
|
else (no)
|
||||||
if (quality < 50) then (yes)
|
if (quality < 50) then (yes)
|
||||||
-increase quality with 1
|
:increase quality with 1;
|
||||||
else (no)
|
else (no)
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
|
|||||||
@@ -9,20 +9,20 @@ end note
|
|||||||
if (not "Aged Brie") then (yes)
|
if (not "Aged Brie") then (yes)
|
||||||
if (quality > 0) then (yes)
|
if (quality > 0) then (yes)
|
||||||
if (not "Sulfuras, Hand of Ragnaros") then (yes)
|
if (not "Sulfuras, Hand of Ragnaros") then (yes)
|
||||||
-lower quality with 1
|
:lower quality with 1;
|
||||||
else (no)
|
else (no)
|
||||||
endif
|
endif
|
||||||
else (no)
|
else (no)
|
||||||
endif
|
endif
|
||||||
else (no)
|
else (no)
|
||||||
if (quality < 50) then (yes)
|
if (quality < 50) then (yes)
|
||||||
-increase quality with 1
|
:increase quality with 1;
|
||||||
else (no)
|
else (no)
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
|
|
||||||
if (not "Sulfuras, Hand of Ragnaros") then (yes)
|
if (not "Sulfuras, Hand of Ragnaros") then (yes)
|
||||||
-lower sell in with 1
|
:lower sell in with 1;
|
||||||
else (no)
|
else (no)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
@@ -30,14 +30,14 @@ if (sell in < 0) then (yes)
|
|||||||
if (not "Aged Brie") then (yes)
|
if (not "Aged Brie") then (yes)
|
||||||
if (quality > 0) then (yes)
|
if (quality > 0) then (yes)
|
||||||
if (not "Sulfuras, Hand of Ragnaros") then (yes)
|
if (not "Sulfuras, Hand of Ragnaros") then (yes)
|
||||||
-lower quality with 1
|
:lower quality with 1;
|
||||||
else (no)
|
else (no)
|
||||||
endif
|
endif
|
||||||
else (no)
|
else (no)
|
||||||
endif
|
endif
|
||||||
else (no)
|
else (no)
|
||||||
if (quality < 50) then (yes)
|
if (quality < 50) then (yes)
|
||||||
-increase quality with 1
|
:increase quality with 1;
|
||||||
else (no)
|
else (no)
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
|
|||||||
@@ -9,25 +9,25 @@ end note
|
|||||||
if (not "Aged Brie" and not "Backstage passes to a TAFKAL80ETC concert") then (yes)
|
if (not "Aged Brie" and not "Backstage passes to a TAFKAL80ETC concert") then (yes)
|
||||||
if (quality > 0) then (yes)
|
if (quality > 0) then (yes)
|
||||||
if (not "Sulfuras, Hand of Ragnaros") then (yes)
|
if (not "Sulfuras, Hand of Ragnaros") then (yes)
|
||||||
-lower quality with 1
|
:lower quality with 1;
|
||||||
else (no)
|
else (no)
|
||||||
endif
|
endif
|
||||||
else (no)
|
else (no)
|
||||||
endif
|
endif
|
||||||
else (no)
|
else (no)
|
||||||
if (quality < 50) then (yes)
|
if (quality < 50) then (yes)
|
||||||
-increase quality with 1
|
:increase quality with 1;
|
||||||
if ("Backstage passes to a TAFKAL80ETC concert") then (yes)
|
if ("Backstage passes to a TAFKAL80ETC concert") then (yes)
|
||||||
if (sell in < 11) then (yes)
|
if (sell in < 11) then (yes)
|
||||||
if (quality < 50) then (yes)
|
if (quality < 50) then (yes)
|
||||||
-increase quality with 1
|
:increase quality with 1;
|
||||||
else (no)
|
else (no)
|
||||||
endif
|
endif
|
||||||
else (no)
|
else (no)
|
||||||
endif
|
endif
|
||||||
if (sell in < 6) then (yes)
|
if (sell in < 6) then (yes)
|
||||||
if (quality < 50) then (yes)
|
if (quality < 50) then (yes)
|
||||||
-increase quality with 1
|
:increase quality with 1;
|
||||||
else (no)
|
else (no)
|
||||||
endif
|
endif
|
||||||
else (no)
|
else (no)
|
||||||
@@ -39,7 +39,7 @@ else (no)
|
|||||||
endif
|
endif
|
||||||
|
|
||||||
if (not "Sulfuras, Hand of Ragnaros") then (yes)
|
if (not "Sulfuras, Hand of Ragnaros") then (yes)
|
||||||
-lower sell in with 1
|
:lower sell in with 1;
|
||||||
else (no)
|
else (no)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
@@ -48,17 +48,17 @@ if (sell in < 0) then (yes)
|
|||||||
if (not "Backstage passes to a TAFKAL80ETC concert") then (yes)
|
if (not "Backstage passes to a TAFKAL80ETC concert") then (yes)
|
||||||
if (quality > 0) then (yes)
|
if (quality > 0) then (yes)
|
||||||
if (not "Sulfuras, Hand of Ragnaros") then (yes)
|
if (not "Sulfuras, Hand of Ragnaros") then (yes)
|
||||||
-lower quality with 1
|
:lower quality with 1;
|
||||||
else (no)
|
else (no)
|
||||||
endif
|
endif
|
||||||
else (no)
|
else (no)
|
||||||
endif
|
endif
|
||||||
else (no)
|
else (no)
|
||||||
-lower quality with quality
|
:lower quality with quality;
|
||||||
endif
|
endif
|
||||||
else (no)
|
else (no)
|
||||||
if (quality < 50) then (yes)
|
if (quality < 50) then (yes)
|
||||||
-increase quality with 1
|
:increase quality with 1;
|
||||||
else (no)
|
else (no)
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
|
|||||||
Reference in new issue
Block a user