Made pageloading and waiting for title work
Refactored common setup
added helper function to wait for element displayed