Commit 6757aaa1 authored by Grzegorz Bizon's avatar Grzegorz Bizon

Improve build status specs contexts descriptions

parent ac115a9e
- status = local_assigns.fetch(:status)
- if status.has_details?
= link_to status.details_path, class: "ci-status ci-#{status}" do
= custom_icon(status.icon)
......
......@@ -65,7 +65,7 @@ describe Gitlab::Ci::Status::Build::Cancelable do
describe '.matches?' do
subject { described_class.matches?(build, user) }
context 'build is cancelable' do
context 'when build is cancelable' do
let(:build) do
create(:ci_build, :running)
end
......
......@@ -51,7 +51,7 @@ describe Gitlab::Ci::Status::Build::Play do
describe '.matches?' do
subject { described_class.matches?(build, user) }
context 'build is playable' do
context 'when build is playable' do
context 'when build stops an environment' do
let(:build) do
create(:ci_build, :playable, :teardown_environment)
......
......@@ -65,7 +65,7 @@ describe Gitlab::Ci::Status::Build::Retryable do
describe '.matches?' do
subject { described_class.matches?(build, user) }
context 'build is retryable' do
context 'when build is retryable' do
let(:build) do
create(:ci_build, :success)
end
......
......@@ -53,7 +53,7 @@ describe Gitlab::Ci::Status::Build::Stop do
describe '.matches?' do
subject { described_class.matches?(build, user) }
context 'build is playable' do
context 'when build is playable' do
context 'when build stops an environment' do
let(:build) do
create(:ci_build, :playable, :teardown_environment)
......
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