issue_4049_fix_object_lookup_spec.rb 500 B

12345678910111213141516
  1. # Copyright (C) 2012-2024 Zammad Foundation, https://zammad-foundation.org/
  2. require 'rails_helper'
  3. RSpec.describe Issue4049FixObjectLookup, type: :db_migration do
  4. before do
  5. # create and update to wrong state in pre release
  6. ObjectLookup.by_name('SMIMECertificate')
  7. ObjectLookup.find_by(name: 'SMIMECertificate').update(name: 'SmimeCertificate')
  8. end
  9. it 'does fix the broken object lookup' do
  10. migrate
  11. expect(ObjectLookup.by_name('SMIMECertificate')).not_to be_nil
  12. end
  13. end