From aa8ab84f4ccc6a05922196a94419dc9f62f34745 Mon Sep 17 00:00:00 2001 From: Dylan Chun Wong Date: Mon, 4 Aug 2014 11:18:15 -0700 Subject: [PATCH] update region and city locators to be more robust and match country locator --- pages/profile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pages/profile.py b/pages/profile.py index 0b5c2c7..d062dea 100644 --- a/pages/profile.py +++ b/pages/profile.py @@ -24,8 +24,8 @@ class Profile(Base): _groups_locator = (By.ID, 'groups') _languages_locator = (By.ID, 'languages') _location_locator = (By.ID, 'location') - _city_locator = (By.CSS_SELECTOR, '#location > a:nth-child(2)') - _region_locator = (By.CSS_SELECTOR, '#location > a:nth-child(3)') + _city_locator = (By.CSS_SELECTOR, '#location .locality') + _region_locator = (By.CSS_SELECTOR, '#location .region') _country_locator = (By.CSS_SELECTOR, '#location .country-name') _profile_message_locator = (By.CSS_SELECTOR, '.alert') _view_as_locator = (By.ID, 'view-privacy-mode')