Browse Source

add #household_charge to bulk upload

remotes/origin/bulk-upload-errors-integration
Phil Lee 3 years ago
parent
commit
8175fc53fb
  1. 2
      app/services/bulk_upload/lettings/row_parser.rb
  2. 8
      spec/services/bulk_upload/lettings/row_parser_spec.rb

2
app/services/bulk_upload/lettings/row_parser.rb

@ -321,6 +321,7 @@ private
period: %i[field_79],
brent: %i[field_80],
household_charge: %i[field_86],
hbrentshortfall: %i[field_87],
tshortfall: %i[field_88],
@ -511,6 +512,7 @@ private
attributes["period"] = field_79
attributes["brent"] = field_80
attributes["household_charge"] = field_86
attributes["hbrentshortfall"] = field_87
attributes["tshortfall_known"] = tshortfall_known
attributes["tshortfall"] = field_88

8
spec/services/bulk_upload/lettings/row_parser_spec.rb

@ -573,5 +573,13 @@ RSpec.describe BulkUpload::Lettings::RowParser do
expect(parser.log.ppcodenk).to eq(0)
end
end
describe "#household_charge" do
let(:attributes) { { bulk_upload:, field_86: "1" } }
it "sets correct value from mapping" do
expect(parser.log.household_charge).to eq(1)
end
end
end
end

Loading…
Cancel
Save