mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-01-24 20:36:49 +00:00
Better error for VineVoucherValidatorService
Co-authored-by: David Cook <david@redcliffs.net>
This commit is contained in:
committed by
Rachel Arnould
parent
d7313ffec9
commit
e7ece294cc
@@ -576,10 +576,10 @@ en:
|
||||
payment_could_not_complete: "The payment could not be completed"
|
||||
vine_voucher_validator_service:
|
||||
errors:
|
||||
vine_settings: "No Vine api settings for the given enterprise"
|
||||
vine_api: "There was an error communicating with the API"
|
||||
vine_settings: "This shop is not enabled for VINE Vouchers."
|
||||
vine_api: "There was an error communicating with the API, please try again later."
|
||||
invalid_voucher: "The voucher is not valid"
|
||||
not_found_voucher: "The voucher doesn't exist"
|
||||
not_found_voucher: "Sorry, we couldn't find that voucher, please check the code."
|
||||
vine_voucher_redeemer_service:
|
||||
errors:
|
||||
vine_settings: "No Vine api settings for the given enterprise"
|
||||
|
||||
@@ -199,7 +199,7 @@ RSpec.describe Vine::VoucherRedeemerService, feature: :connected_apps do
|
||||
voucher_redeemer_service.redeem
|
||||
|
||||
expect(voucher_redeemer_service.errors).to include(
|
||||
{ vine_api: "There was an error communicating with the API" }
|
||||
{ vine_api: "There was an error communicating with the API, please try again later." }
|
||||
)
|
||||
end
|
||||
|
||||
|
||||
@@ -78,7 +78,7 @@ RSpec.describe Vine::VoucherValidatorService, feature: :connected_apps do
|
||||
validate_voucher_service.validate
|
||||
|
||||
expect(validate_voucher_service.errors).to include(
|
||||
{ vine_settings: "No Vine api settings for the given enterprise" }
|
||||
{ vine_settings: "This shop is not enabled for VINE Vouchers." }
|
||||
)
|
||||
end
|
||||
|
||||
@@ -106,7 +106,7 @@ RSpec.describe Vine::VoucherValidatorService, feature: :connected_apps do
|
||||
validate_voucher_service.validate
|
||||
|
||||
expect(validate_voucher_service.errors).to include(
|
||||
{ vine_api: "There was an error communicating with the API" }
|
||||
{ vine_api: "There was an error communicating with the API, please try again later." }
|
||||
)
|
||||
end
|
||||
|
||||
@@ -150,7 +150,7 @@ RSpec.describe Vine::VoucherValidatorService, feature: :connected_apps do
|
||||
validate_voucher_service.validate
|
||||
|
||||
expect(validate_voucher_service.errors).to include(
|
||||
{ vine_api: "There was an error communicating with the API" }
|
||||
{ vine_api: "There was an error communicating with the API, please try again later." }
|
||||
)
|
||||
end
|
||||
|
||||
@@ -186,7 +186,7 @@ RSpec.describe Vine::VoucherValidatorService, feature: :connected_apps do
|
||||
validate_voucher_service.validate
|
||||
|
||||
expect(validate_voucher_service.errors).to include(
|
||||
{ not_found_voucher: "The voucher doesn't exist" }
|
||||
{ not_found_voucher: "Sorry, we couldn't find that voucher, please check the code." }
|
||||
)
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user