Skip to content

OpenProject is the leading open source project management software for product, project and portfolio management. A powerful Jira alternative with agile planning, issue tracking, roadmaps, Gantt charts, time tracking, collaboration features, and more. Available on premises or in the cloud. ⭐ Star us on GitHub

418 B
Raw Blame
# frozen_string_literal: true

RSpec.configure do |c|
  ##
  # Session-based API authentication requires the X-requested-with header to be present.
  c.before(:each, type: :request) do |ex|
    unless ex.metadata[:skip_xhr_header]
      header("X-Requested-With", "XMLHttpRequest")
    end
  end

  c.before(:each, content_type: :json, type: :request) do |_ex|
    header("Content-Type", "application/json")
  end
end