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