first unit test for UIComponent; small changes in the class to make unit testing possible
small change in setTemplate() and more unit test cases for it