test-authorize-net-payment
setTimeout 120000
deleteAllVisibleCookies
open wp-admin
clickAndWait link=Pages
clickAndWait css=a.add-new-h2
type title Error
type content [yak_error_message]

[yak_back_to_address]

[yak_back_to_cc]
clickAndWait publish
clickAndWait link=General Options
click payments-tab
type //input[@name='payment_type_names[]' and @value=''] Credit Card (auth.net)
select //table[@id='payment_types']/tbody/tr[6]/td[2]/select label=SPECIAL: Authorize.net (Test)
type yak_authorize_login_id ${authorizenetLogin}
type yak_authorize_trans_key ${authorizenetTransactionKey}
select yak_authorize_landing_page label=Thanks for your order
click yak_authorize_test_mode
select yak_authorize_error_page label=Error
clickAndWait options_update5
clickAndWait link=Visit Site
clickAndWait link=test-product-weight
clickAndWait //button[@name='addbutton']
select payment_type label=Credit Card (auth.net)
clickAndWait buybutton
clickAndWait shippingbutton
type cc_number 4111111111111111
type cc_security_code 000
type cc_name JOE BLOGGS
select cc_expiry_year label=2022
clickAndWait confirmbutton
clickAndWait confirmorderbutton
assertTextPresent Order value: $25.00
open
clickAndWait //button[@name='addbutton']
select payment_type label=Credit Card (auth.net)
clickAndWait buybutton
clickAndWait shippingbutton
type cc_number 4222222222222
type cc_security_code 000
type cc_name JOE BLOGGS
select cc_expiry_year label=2022
clickAndWait confirmbutton
clickAndWait confirmorderbutton
assertTextPresent Error
clickAndWait back_to_address
assertTextPresent Shipping Address
clickAndWait shippingbutton
type cc_number 4222222222222
type cc_security_code 000
type cc_name JOE BLOGGS
select cc_expiry_year label=2022
clickAndWait confirmbutton
clickAndWait confirmorderbutton
clickAndWait back_to_credit_card
assertTextPresent Please enter your credit card details