Skip to content

Commit

Permalink
Merge pull request #2391 from samvera/fix-field-mappings-spec
Browse files Browse the repository at this point in the history
Prevent field mappings set value from bleeding into other specs
  • Loading branch information
bkiahstroud authored Nov 26, 2024
2 parents 36c6aab + cda7724 commit d427e24
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions spec/lib/bulkrax/bulkrax_decorator_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,12 @@
allow(Site.account).to receive(:bulkrax_field_mappings).and_return nil
end

around do |example|
initialized_defaults = Hyku.default_bulkrax_field_mappings
example.run
Hyku.default_bulkrax_field_mappings = initialized_defaults
end

it "returns Hyku's default field mappings" do
Hyku.default_bulkrax_field_mappings = { this: 'is fine' }

Expand Down

0 comments on commit d427e24

Please sign in to comment.