Hello!
Gilded Doghouse is a pet shop where we sell dog treats (but not only). We group products into categories; each day, we update the days remaining (expiry date) and the quality of the goodies. The categories are Normal Item, Aged Bone, Backstage Training Session, Coursedog Mascot. Each item category has its own rules to handle expiry dates and quality.
We want to introduce a new category: Beef Cake. For that, we're looking for someone to implement the expiry logic in our system.
Existing logic is covered by our unit tests available in gilded_doghouse.test.js
. It also contains six skipped tests to guide you. The tests describe how we want to handle Beef Cakes. Your job is to reenable the tests and -- obviously -- implement the Beef Cake in our system.
Requirements:
- The system must behave the same way it does
- All of the tests must be green
- You're free to refactor the system if you want to
Happy hacking!