2017-12-03 15:02:14 +00:00
|
|
|
from datetime import datetime
|
|
|
|
|
|
|
|
|
|
|
|
class BasePageObject(object):
|
|
|
|
|
|
|
|
def __init__(self, driver):
|
|
|
|
self.driver = driver
|
|
|
|
|
|
|
|
def get_url(self, url):
|
|
|
|
self.driver.get(url)
|
|
|
|
|
|
|
|
def refresh(self):
|
|
|
|
self.driver.refresh()
|
|
|
|
|
|
|
|
@property
|
|
|
|
def time_now(self):
|
|
|
|
return datetime.now().strftime('%-m%-d%-H%-M%-S')
|
2018-01-26 18:12:58 +00:00
|
|
|
|
|
|
|
@property
|
|
|
|
def current_url(self):
|
|
|
|
return self.driver.current_url
|