File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -246,7 +246,7 @@ def performed_ods_code = @data[:organisation_code]
246246
247247 def programme_name = poc? ? @data [ :programme ] : nil
248248
249- def reason_not_administered = @data [ :reason_not_vaccinated ]
249+ def reason_not_administered = poc? ? @data [ :reason_not_vaccinated ] : nil
250250
251251 def school_name =
252252 if poc?
Original file line number Diff line number Diff line change 10191019 end
10201020 end
10211021
1022+ shared_examples "when Mavis columns are present, which the bulk upload should ignore" do
1023+ let ( :data ) do
1024+ valid_bulk_flu_data . merge (
1025+ {
1026+ "PROGRAMME" => "HPV" ,
1027+ "PERFORMING_PROFESSIONAL_EMAIL" => "abc123@example.com" ,
1028+ "NOTES" => "Here are some notes" ,
1029+ "CARE_SETTING" => 2 ,
1030+ "CLINIC_NAME" => "The Hog's Head" ,
1031+ "SESSION_ID" => 1 ,
1032+ "UUID" => "ABCD1234-26cc-44e4-b886-c3cc90ba01b6" ,
1033+ "REASON_NOT_VACCINATED" => "Unwell"
1034+ }
1035+ )
1036+ end
1037+
1038+ it "ignores the Mavis columns" do
1039+ expect ( immunisation_import_row ) . to be_valid
1040+ end
1041+ end
1042+
10221043 context "of unknown type (no VACCINE_GIVEN)" do
10231044 context "with an empty row" do
10241045 let ( :data ) { { } }
10961117 end
10971118
10981119 include_examples "when `VACCINATED` is `N`"
1120+
1121+ include_examples "when Mavis columns are present, which the bulk upload should ignore"
10991122 end
11001123
11011124 context "of type hpv" do
11271150 end
11281151
11291152 include_examples "when `VACCINATED` is `N`"
1153+
1154+ include_examples "when Mavis columns are present, which the bulk upload should ignore"
11301155 end
11311156 end
11321157 end
23112336 "CARE_SETTING" => 2 ,
23122337 "CLINIC_NAME" => "The Hog's Head" ,
23132338 "SESSION_ID" => session . id ,
2314- "UUID" => "ABCD1234-26cc-44e4-b886-c3cc90ba01b6"
2339+ "UUID" => "ABCD1234-26cc-44e4-b886-c3cc90ba01b6" ,
2340+ "REASON_NOT_VACCINATED" => "Unwell"
23152341 }
23162342 )
23172343 end
You can’t perform that action at this time.
0 commit comments