UI-9 Added unit tests to ensure that the elements on the DOM do not exceed window size