BRIDGE-588_update_paytostored_e2e_test # Summary Update the pay-to-stored-worldpay-account.e2e.spec.js file with the new method of testing which uses e2e-helper.js # Test Plan * Unit tests run and pass ```bash E2E: dev api Worldpay payment for saved merchant request tests with missing required parameters ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:25 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with no paymentInstrument parameters (60ms) ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:25 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with no receiveInstrument parameters ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:25 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with no amount parameter ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:25 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with no transactionDetails parameter ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:25 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with no paymentInstrument.payer parameters ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:25 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with no paymentInstrument.payer.email parameter ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:25 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with no paymentInstrument.payer.firstName parameter ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:25 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with no paymentInstrument.payer.lastName parameter ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:25 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with no paymentInstrument.card parameters ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:25 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with no paymentInstrument.card.nameOnCard parameter ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:25 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with no paymentInstrument.card.PAN parameter ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:25 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with no paymentInstrument.card.expiryDate parameter ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:25 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with no paymentInstrument.card.address parameter ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:25 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with no paymentInstrument.card.address.address1 parameter ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:25 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with no paymentInstrument.card.address.town parameter ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:26 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with no paymentInstrument.card.address.postcode parameter ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:26 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with no transactionDetails.worldpay parameters ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:26 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with no receiving account encryption key bad data format tests ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:26 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with an invalid paymentInstrument email parameter ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:26 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with an invalid payer first name parameter ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:26 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with an invalid payer last name parameter ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:26 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with a bad card PAN parameter containing a letter ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:26 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with a bad card PAN parameter with a trailing space ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:26 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with a bad character in the payment card expiry date parameter ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:26 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with a bad month number in the payment card expiry date parameter ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:26 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with a badly formatted payment card start date parameter ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:26 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with a bad month number in the payment card start date parameter ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:26 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with a badly formatted payment card issue number parameter ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:26 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with a badly formatted payment card CV2 parameter ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:26 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with a card address line 1 too long ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:26 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with a card address line 1 too short ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:26 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with a badly formatted card address line 2 parameter ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:26 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with a badly formatted card address line 3 parameter ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:26 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with a badly formatted card address town name parameter ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:26 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with a badly formatted card address county name parameter ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:26 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with a badly formatted card address postcode parameter ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:26 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with a badly formatted card address phone number parameter ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:26 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with a badly formatted order description parameter ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:26 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with a badly formatted receiving account encryption key parameter ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:26 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with a badly formatted amount value parameter - with a badly formatted instrument ID invalid card ID ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:26 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/aaaaaa/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ with a short card ID ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:26 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/zzzzzzzzzzzzzzzzzzzzzzzz/payments HTTP/1.1" 400 - "-" "node-superagent/3.8.2" ✓ card ID with an invalid pattern Good parameter data tests [2018-03-23T10:42:26.532Z undefined (VIP undefined)] CRITICAL (mainDB.findOneObject) from System at 127.0.0.1: Database offline; cannot find object. TRIED TO FIND: {"_id":"deadbeefdeadbeefdeadbeef","UserID":"79a26d981246978135edadf1","AccountType":"Worldpay Online Payments Account"} ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:26 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 502 33 "-" "node-superagent/3.8.2" ✓ with the minimum set of correct parameters [2018-03-23T10:42:26.548Z undefined (VIP undefined)] CRITICAL (mainDB.findOneObject) from System at 127.0.0.1: Database offline; cannot find object. TRIED TO FIND: {"_id":"deadbeefdeadbeefdeadbeef","UserID":"79a26d981246978135edadf1","AccountType":"Worldpay Online Payments Account"} ::ffff:127.0.0.1 - 79a26d981246978135edadf1 [23/Mar/2018:10:42:26 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 502 33 "-" "node-superagent/3.8.2" ✓ with a full set of correct parameters authorization ::ffff:127.0.0.1 - - [23/Mar/2018:10:42:26 +0000] "POST /dev/v0/payment-instruments/worldpay-merchants/deadbeefdeadbeefdeadbeef/payments HTTP/1.1" 401 - "-" "node-superagent/3.8.2" ✓ is required to access the path 45 passing (1s) 1 pending ```