Browse Source

Merge branch 'main' into CLDC-4140-remove-old-gender-question-lettings

CLDC-4140-remove-old-gender-question-lettings
Nat Dean-Lewis 2 days ago
parent
commit
2062ab148d
  1. 32
      app/services/bulk_upload/lettings/year2026/row_parser.rb
  2. 4
      spec/services/bulk_upload/lettings/year2026/row_parser_spec.rb

32
app/services/bulk_upload/lettings/year2026/row_parser.rb

@ -1236,22 +1236,22 @@ private
county: [:field_22], county: [:field_22],
uprn_selection: [:field_19], uprn_selection: [:field_19],
gender_same_as_sex1: %i[field_130], gender_same_as_sex1: %i[field_138],
gender_same_as_sex2: %i[field_131], gender_same_as_sex2: %i[field_140],
gender_same_as_sex3: %i[field_132], gender_same_as_sex3: %i[field_142],
gender_same_as_sex4: %i[field_133], gender_same_as_sex4: %i[field_144],
gender_same_as_sex5: %i[field_134], gender_same_as_sex5: %i[field_146],
gender_same_as_sex6: %i[field_135], gender_same_as_sex6: %i[field_148],
gender_same_as_sex7: %i[field_136], gender_same_as_sex7: %i[field_150],
gender_same_as_sex8: %i[field_137], gender_same_as_sex8: %i[field_152],
gender_description1: %i[field_138], gender_description1: %i[field_139],
gender_description2: %i[field_139], gender_description2: %i[field_141],
gender_description3: %i[field_140], gender_description3: %i[field_143],
gender_description4: %i[field_141], gender_description4: %i[field_145],
gender_description5: %i[field_142], gender_description5: %i[field_147],
gender_description6: %i[field_143], gender_description6: %i[field_149],
gender_description7: %i[field_144], gender_description7: %i[field_151],
gender_description8: %i[field_145], gender_description8: %i[field_153],
}.compact }.compact
end end

4
spec/services/bulk_upload/lettings/year2026/row_parser_spec.rb

@ -2088,9 +2088,9 @@ RSpec.describe BulkUpload::Lettings::Year2026::RowParser do
it "does not add errors to fields that are not routed to" do it "does not add errors to fields that are not routed to" do
parser.valid? parser.valid?
expect(parser.errors.where(:field_157, category: :soft_validation)).not_to be_present expect(parser.errors.where(:field_47, category: :soft_validation)).not_to be_present
expect(parser.errors.where(:field_136, category: :soft_validation)).not_to be_present expect(parser.errors.where(:field_136, category: :soft_validation)).not_to be_present
expect(parser.errors.where(:field_161, category: :soft_validation)).not_to be_present expect(parser.errors.where(:field_61, category: :soft_validation)).not_to be_present
expect(parser.errors.where(:field_138, category: :soft_validation)).not_to be_present expect(parser.errors.where(:field_138, category: :soft_validation)).not_to be_present
end end
end end

Loading…
Cancel
Save