added test case for accessing window object