Added logging, icon creation and some unit tests