Skip to content

Commit

Permalink
Merge pull request #74 from commercetools/fix-tests
Browse files Browse the repository at this point in the history
Update tests
  • Loading branch information
lojzatran authored Jul 4, 2019
2 parents 19a0f14 + 08db9a7 commit 6003f7d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion extension/cypress/integration/credit_card_3ds.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ describe('Credit card 3DS 1.0', () => {
cy.get('#paymentObject')
.should(($div) => {
const paymentObject = JSON.parse($div.text())
expect(paymentObject.body.transactions[0].interactionId).match(/^[0-9]*$/)
expect(paymentObject.body.transactions[0].interactionId).match(/^[0-9a-zA-Z]*$/)
})
})
})
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ describe('credit card payment', () => {
expect(transactions).to.have.lengthOf(1)
expect(transactions[0].type).to.equal('Charge')
expect(transactions[0].state).to.equal('Success')
expect(transactions[0].interactionId).to.match(/^[0-9]*$/)
expect(transactions[0].interactionId).to.match(/^[0-9a-zA-Z]*$/)
})

it('should create 3ds redirect', async () => {
Expand Down Expand Up @@ -124,7 +124,7 @@ describe('credit card payment', () => {
expect(adyenRequestBody.paymentMethod.encryptedSecurityCode).to.have.string('adyenjs_')

const adyenResponse = JSON.parse(ctpPayment.interfaceInteractions[0].fields.response)
expect(adyenResponse.errorCode).to.match(/^[0-9]*$/)
expect(adyenResponse.errorCode).to.match(/^[0-9a-zA-Z]*$/)
expect(adyenResponse.errorType).to.equal('validation')
const { transactions } = ctpPayment
expect(transactions).to.have.lengthOf(1)
Expand Down

0 comments on commit 6003f7d

Please sign in to comment.