Skip to content

Latest commit

 

History

History
20 lines (12 loc) · 1.2 KB

README.md

File metadata and controls

20 lines (12 loc) · 1.2 KB

"Sing a song" refactoring kata

Objective

Code to produce a popular children's nursary rhyme was produced by a web agency for the customer last year. No documentation or tests were provided by the previous developer.

The customer now desires to produce multiple different versions of the song using the same structure but based on different themes, for example a current popular children's movie featuring a cast of animals. The customer asks that you make the song configurable for different lists of animals. The customer cannot guarentee that there will be the same number of animals in each different version.

Refactor the code to allow for the customer's needs. Remember:

Refactoring can only be done in the presence of tests that are passing, and after refactoring the tests still pass! ✅

What to do?

The functionality is in the file src/song.ts. Check the package.json for prepared scripts, feel free to use/add/modify them.

  • create branch called by your name and then push your progress there
  • add tests to cover the current functionality
  • refactor the code in src/song.ts to match the objective and be awesome

You have one hour, good luck! ⏱