OpenProject is the leading open source project management software.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
openproject/spec/spec_helper.rb

17 lines
393 B

# -- load spec_helper from OpenProject core
require "spec_helper"
7 years ago
RSpec.configure do |config|
config.before(:each) do |example|
next unless example.metadata[:with_2fa_ee]
allow(EnterpriseToken)
.to receive(:allows_to?)
.and_call_original
allow(EnterpriseToken)
.to receive(:allows_to?)
.with(:two_factor_authentication)
.and_return true
end
end