Added some UI tests and fixed some UI code to fix failing tests