Clean up the tests a little bit.
Use sync for all accesses of UI elements that might not exist on page yet.