Commit 95c29671 authored by James Lopez's avatar James Lopez

fix spec failure

parent b4a7fcc3
......@@ -3,16 +3,17 @@ require 'spec_helper'
describe ::Applications::CreateService do
let(:user) { create(:user) }
let(:params) { attributes_for(:application) }
let(:request) { ActionController::TestRequest.new(remote_ip: '127.0.0.1') }
subject { described_class.new(user, params) }
it 'creates an application' do
expect { subject.execute }.to change { Doorkeeper::Application.count }.by(1)
expect { subject.execute(request) }.to change { Doorkeeper::Application.count }.by(1)
end
it 'creates an audit log' do
stub_licensed_features(extended_audit_events: true)
expect { subject.execute }.to change { SecurityEvent.count }.by(1)
expect { subject.execute(request) }.to change { SecurityEvent.count }.by(1)
end
end
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment