Changed jsdom to return the parent window instead of creating a new one