kunwardeep/test-api

[Field account_number] - In correct error message when account number is 5 or 10 characters long and bank country code is AU

Opened this issue · 0 comments

Testing Endpoint - http://preview.airwallex.com:30001
request - POST
JSON payload - 5 characters

{ 
 payment_method: 'LOCAL',
 bank_country_code: 'AU',
 account_name: 'John Smith',
 account_number: '01234',
 bsb: '012345'
}

JSON payload - 10 characters

{ 
 payment_method: 'LOCAL',
 bank_country_code: 'AU',
 account_name: 'John Smith',
 account_number: '0123456789',
 bsb: '012345'
}

Both the cases lead to the same result

Result

+ expected - actual

  {
    -  "error": "Length of account_number should be between 7 and 11 when bank_country_code is 'US'"
    +  "error": "Length of account_number should be between 6 and 9 when bank_country_code is 'AU'"
  }

To reproduce run test -

Save Bank Details with account_number field
  And bank country code - AU
    And invalid length