Commit Graph

4 Commits

Author SHA1 Message Date
Maarten Parmentier
cc494bf27e Extract normal item cases
All tests pass, both rspec as texttests. This gives me a good base to start implementing Conjured items.
The idea is to implement Conjured items first before starting to clean up the code.
My thought process when implementing new code is always: make it work -> make it safe -> clean it up
2023-06-27 20:37:29 +02:00
Maarten Parmentier
14363a173b Extract Backstage Passes 2023-06-27 20:32:24 +02:00
Maarten Parmentier
3d86d3d0ef Extract 'Aged Brie'
Also noticed I made a mistake in some specs, would normally optimise spec code later on.
Added an extra test for when sell_in is 1 for safety as it depends on the order of operations in the extraction I make.
2023-06-27 20:22:05 +02:00
Maarten Parmentier
f0204a4b1e Write tests for all types of items
Without looking at the code I've written specs based on the requirements listed and the output of the texttest.
All specs are green except for the expected 2 failing 'quality' tests for the new 'Conjured' item.
With all models tested I feel more comfortable starting the refactor. The plan at the moment is to extract the code of 1 type of item at the time into it's own method.
2023-06-26 22:57:33 +02:00