adds hot fix for census api failed attempt storage

This commit is contained in:
rgarcia
2016-02-22 11:33:16 +01:00
parent a93a3ed0e5
commit 0e33382912
2 changed files with 6 additions and 4 deletions

View File

@@ -63,8 +63,9 @@ class Verification::Residence
document_number: document_number, document_number: document_number,
document_type: document_type, document_type: document_type,
date_of_birth: date_of_birth, date_of_birth: date_of_birth,
postal_code: postal_code, postal_code: postal_code
district_code: district_code #hot fix. Check out the Census API to catch the exception earlier.
#district_code: district_code
}) })
end end

View File

@@ -112,6 +112,7 @@ describe Verification::Residence do
end end
end end
#Pending fix to Census API response for district code.
describe "Failed census call" do describe "Failed census call" do
it "stores failed census API calls" do it "stores failed census API calls" do
residence = build(:verification_residence, :invalid, document_number: "12345678Z") residence = build(:verification_residence, :invalid, document_number: "12345678Z")
@@ -123,8 +124,8 @@ describe Verification::Residence do
document_number: "12345678Z", document_number: "12345678Z",
document_type: "1", document_type: "1",
date_of_birth: Date.new(1980, 12, 31), date_of_birth: Date.new(1980, 12, 31),
postal_code: "28001", postal_code: "28001"
district_code: "01" #district_code: "01"
}) })
end end
end end