jasmine.Popup trimHeight reduces height if there is not enough space on the bottom (from jasmine.specs)