diff options
author | Marcello Stanisci <marcello.stanisci@inria.fr> | 2017-10-17 13:30:55 +0200 |
---|---|---|
committer | Marcello Stanisci <marcello.stanisci@inria.fr> | 2017-10-17 13:30:55 +0200 |
commit | d951a87bc4ba36933a13dadf6ffc2a5a89543086 (patch) | |
tree | 09b92e8072a742a2226d99d2d6e04e398f51cd55 /selenium | |
parent | f7585780bf35674066be9b02aa9af95ff0fda6c5 (diff) |
selenium wrong class attribute
Diffstat (limited to 'selenium')
-rw-r--r-- | selenium/withdraw_buy.py | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/selenium/withdraw_buy.py b/selenium/withdraw_buy.py index 4a014782b..bc543143d 100644 --- a/selenium/withdraw_buy.py +++ b/selenium/withdraw_buy.py @@ -127,7 +127,8 @@ def make_donation(client, amount_menuentry=None): abort(client) confirm_taler.click() # Taler as payment option chosen try: - confirm_pay = wait.until(EC.element_to_be_clickable((By.XPATH, "//button[@class='accept']"))) + confirm_pay = wait.until(EC.element_to_be_clickable((By.XPATH, + "//button[@class='pure-button button-success']"))) except TimeoutException: logger.error('Could not confirm payment on donation shop') abort(client) @@ -167,7 +168,8 @@ def buy_article(client, title, fulfillment_url=None): abort(client) time.sleep(1) try: - confirm_pay = wait.until(EC.element_to_be_clickable((By.XPATH, "//button[@class='accept']"))) + confirm_pay = wait.until(EC.element_to_be_clickable((By.XPATH, + "//button[@class='pure-button button-success']"))) logger.info("Pay button turned clickable") except TimeoutException: logger.error('Could not confirm payment on blog') @@ -308,7 +310,8 @@ client.delete_all_cookies() ret = buy_article(client, "25._The_Danger_of_Software_Patents", fulfillment_url_25) logger.info("Donating..") make_donation(client, "1.0 TESTKUDOS") -logger.info("Bookmarked purchase: '%s'" % ret) +# FIXME: better clearing the cache before replaying the payment +logger.info("Payment replayed: '%s'" % ret) logger.info("Test passed") client.quit() if hasattr(display, "old_display_var"): |