Logo: Relish

  1. Sign in

Project: Icepak annual_plans

Transactions

  • @javascript
  • @vcr
Scenarios
Required fields
Given
I am logged in
When
I go to the Subscribers page
And
I fill in "criteria" with "[email protected]"
And
I press "search"
And
I click "Transactions"
Then
I should see the following table rows:
Card Date Amount Status Transaction Id
Visa 1111 2013-07-25T19:51:15+00:00 $1.99 purchase success 21862de5d782e3cfade79f4e53878adc
And
I click "21862de5d782e3cfade79f4e53878adc"
And
I should see "Transaction Details invoice #4189 Refund"
Then
I should see the following table rows:
Type purchase
Date 2013-07-25T19:51:15+00:00
Amount $1.99
Status success
Method Visa
Credit Card 4111-11XX-XXXX-1111
Billing Address 88 morgan st #801 jersey city NJ 07302
And
I click "Refund"
And
wait 1 seconds for ajax to process
And
I press "Refund Transaction"
Then
I should see "Please enter a reason for refunding"
And
I should see "Please enter a remark"
Fully Refunding a transaction
Given
I am logged in
When
I go to the Subscribers page
And
I fill in "criteria" with "[email protected]"
And
I press "search"
And
I click "Transactions"
Then
I should see the following table rows:
Card Date Amount Status Transaction Id
Visa 1111 2013-10-10T19:40:15+00:00 $4.99 purchase success 2312ad7f95f8e79b1c0cde4ee9834345
And
I click "2312ad7f95f8e79b1c0cde4ee9834345"
And
I should see "Transaction Details invoice #7863 Refund"
Then
I should see the following table rows:
Type purchase
Date 2013-10-10T19:40:15+00:00
Amount $4.99
Status success
Method Visa
Credit Card 4111-11XX-XXXX-1111
Billing Address 88 morgan st #801 jersey city NJ 07302
And
I click "Refund"
And
I select "Buyer Remorse" from "refund_reason_id"
And
I fill in "remark" with "some remark"
And
I press "Refund Transaction"
And
I should see "Transaction Refunded"
Then
I should see the following table rows:
Card Date Amount Status Transaction Id
Visa 1111 2013-10-10T19:40:15+00:00 $4.99 purchase void 2312ad7f95f8e79b1c0cde4ee9834345
And
I should see the following table rows:
Time CSR Action Field From To Remark
anytime [email protected] transaction fully refunded some remark refunded $4.99 Buyer Remorse
Partially refunding a transaction
Given
I am logged in
And
I go to the Subscribers page
And
I fill in "criteria" with "[email protected]"
And
I press "search"
And
I click "Transactions"
Then
I should see the following table rows:
Card Date Amount Status Transaction Id
Visa 1111 2013-10-10T19:55:39+00:00 $2.00 purchase success 2312bb97775c4336f5c6c94cfab8c639
And
I click "2312bb97775c4336f5c6c94cfab8c639"
And
I click "Refund"
And
I fill in "amount" with "0.50"
And
I select "Buyer Remorse" from "refund_reason_id"
And
I fill in "remark" with "some remark"
And
I press "Refund Transaction"
Then
I should see "Transaction Refunded"
And
I should see the following table rows:
Card Date Amount Status Transaction Id
Visa 1111 2013-10-10T19:57:58+00:00 $0.50 refund success 2312bdb6a4aeb37f4ae44b4e93a8d6b1
And
I should see the following table rows:
Time CSR Action Field From To Remark
anytime [email protected] transaction partially refunded some remark refunded $0.50 Buyer Remorse
Partially refunding a transaction then voiding it
Given
I am logged in
When
I go to the Subscribers page
And
I fill in "criteria" with "[email protected]"
And
I press "search"
And
I click "Transactions"
Then
I should see the following table rows:
Card Date Amount Status Transaction Id
Visa 1111 2013-10-10T19:59:53+00:00 $3.00 purchase success 2312bf78dbef28b4ead0624627bc46fb
And
I click "2312bf78dbef28b4ead0624627bc46fb"
And
I click "Refund"
And
I fill in "amount" with "0.49"
And
I select "Buyer Remorse" from "refund_reason_id"
And
I fill in "remark" with "some remark"
And
I press "Refund Transaction"
Then
I should see "Transaction Refunded"
And
I click "2312bf78dbef28b4ead0624627bc46fb"
And
I click "Refund"
And
I select "Buyer Remorse" from "refund_reason_id"
And
I fill in "remark" with "some remark"
And
I press "Refund Transaction"
And
I should see "Transaction Refunded"
Then
I should see the following table rows:
Card Date Amount Status Transaction Id
Visa 1111 2013-10-10T20:01:35+00:00 $0.49 refund success 2312c1064aac7c7176c669403e963684
Visa 1111 2013-10-10T19:59:53+00:00 $3.00 purchase void 2312bf78dbef28b4ead0624627bc46fb
Partially refunding a transaction - bad input
Given
I am logged in
When
I go to the Subscribers page
And
I fill in "criteria" with "[email protected]"
And
I press "search"
And
I click "Transactions"
And
I click "21aa34c8d62cb3855f82c14a6981bff1"
And
I click "Refund"
And
I fill in "amount" with "bad amount"
And
I select "Buyer Remorse" from "refund_reason_id"
And
I fill in "remark" with "some remark"
And
the time is "2013-07-26 15:55:47 UTC"
And
I press "Refund Transaction"
Then
I should see "Failed to refund transaction 422 Unprocessable Entity"
Partial refunds cannot exceed the amount of the transaction
Given
I am logged in
When
I search for a subscriber with the email "[email protected]"
And
I click "Transactions"
And
I click "21aa34c8d62cb3855f82c14a6981bff1"
And
I click "Refund"
And
I fill in "amount" with "9999"
And
I select "Buyer Remorse" from "refund_reason_id"
And
I fill in "remark" with "some remark"
And
the time is "2013-07-26 15:55:47 UTC"
And
I press "Refund Transaction"
Then
I should see "Failed to refund transaction 422 Unprocessable Entity"
Partial refunds equaling the amount of the transaction
Given
I am logged in
When
I search for a subscriber with the email "[email protected]"
And
I click "Transactions"
Then
I should see the following table rows:
Card Date Amount Status Transaction Id
Visa 1111 2013-08-01T20:12:06+00:00 $1.50 purchase success 21aa4d7d66791168fac94e4aada71aad
And
I click "21aa4d7d66791168fac94e4aada71aad"
And
I click "Refund"
And
I fill in "amount" with "0.50"
And
I select "Buyer Remorse" from "refund_reason_id"
And
I fill in "remark" with "some remark"
And
I press "Refund Transaction"
And
I should see "Transaction Refunded"
And
I click "21aa4d7d66791168fac94e4aada71aad"
And
I click "Refund"
And
I fill in "amount" with "1.00"
And
I select "Buyer Remorse" from "refund_reason_id"
And
I fill in "remark" with "some remark"
And
I press "Refund Transaction"
Then
I should see "Transaction Refunded"
And
I click "21aa4d7d66791168fac94e4aada71aad"
Then
I should not see the link "Refund"

Last published over 4 years ago by Edan Rosenberg.