deprecation_toolkit.rb 545 B

12345678910111213141516
  1. # Copyright (C) 2012-2023 Zammad Foundation, https://zammad-foundation.org/
  2. require 'deprecation_toolkit/rspec'
  3. DeprecationToolkit::Configuration.test_runner = :rspec
  4. # Treat Ruby deprecation warnings as errors.
  5. DeprecationToolkit::Configuration.warnings_treated_as_deprecation = [ %r{deprecat}i ]
  6. # Ignore deprecation warnings from dependencies.
  7. DeprecationToolkit::Configuration.allowed_deprecations = [
  8. lambda do |_message, stack|
  9. path = stack.first.absolute_path.to_s
  10. path.include?('/ruby/') || path.include?('/gems/')
  11. end
  12. ]