HACK: make sure the page has rendered by sleeping