Fixed getHeight.
Added tests.