Corrected the test for keepalive and switcher by getting the document instance BEFORE referencing it. D'oh! Added the jQuery test to testSwitcher by mistake previously, but as it is a valid test it has been corrected and left in.