Adds code and tests