Add tests to controllers

It closes #106