Commit 10379f89 authored by Vitali Tatarintev's avatar Vitali Tatarintev

Move subject below lets in specs

parent 55f395ea
......@@ -4,8 +4,6 @@ require 'fast_spec_helper'
describe Gitlab::Alerting::NotificationPayloadParser do
describe '.call' do
subject { described_class.call(payload) }
let(:starts_at) { Time.now.change(usec: 0) }
let(:payload) do
{
......@@ -18,6 +16,8 @@ describe Gitlab::Alerting::NotificationPayloadParser do
}
end
subject { described_class.call(payload) }
it 'returns Prometheus-like payload' do
is_expected.to eq(
{
......
......@@ -11,8 +11,6 @@ describe Projects::Alerting::NotifyService do
end
describe '#execute' do
subject { service.execute }
let(:starts_at) { Time.now.change(usec: 0) }
let(:service) { described_class.new(project, nil, payload) }
let(:payload_raw) do
......@@ -23,6 +21,8 @@ describe Projects::Alerting::NotifyService do
end
let(:payload) { ActionController::Parameters.new(payload_raw).permit! }
subject { service.execute }
context 'with license' do
before do
stub_licensed_features(incident_management: true)
......
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