#1 Test helper to prevent opening of a window