Added a unittest for the main window to test travis ci builds