This kata is inspired by the golden master refactoring method.
You have clean a function already in production. In order to help you in your task, someone has created 105 tests golden master to ensure that the function still works as expecting after your cleaning.
All you know is that the function takes in parameter one string and return a string.
Try to make the code the as easy as possible and readable.
In the src/main/java
folder, you will find the class App
with the current implementation to clean.
You can use mvn test
to test your code. If all tests pass, you don't have break the function !
First install the dependencies with mvn clean install -DskipTests
. Thanks.
Find the easiest implementation. Keep your code as clean as possible (easy to read, understandable ...).