Skip to content

Commit e1c9d7a

Browse files
test: that a change to the discarded_at is staged as a difference
Jira-Issue: MAV-1346
1 parent 04c14ad commit e1c9d7a

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

spec/models/immunisation_import_row_spec.rb

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -940,6 +940,14 @@
940940

941941
it { should_not be_nil }
942942
it { should eq(existing_vaccination_record) }
943+
944+
context "and the record has been previously discarded" do
945+
before { existing_vaccination_record.discard! }
946+
947+
it "stages changes discarded at to nil" do
948+
expect(vaccination_record.pending_changes["discarded_at"]).to be_nil
949+
end
950+
end
943951
end
944952

945953
describe "#batch" do

0 commit comments

Comments
 (0)