Add tests for the UI class

* Suppress debug output for the UI class
* Full coverage of that class
Misc cleanups

* Remove unused imports
* Remove meaningless asserts in tools tests