Refactored to use pageobjects. Not verified to work

Refactored to use pageobjects. Not verified to work