Fixes tests on IE7 and IE9