Commit cbbb6739 authored by Marcia Ramos's avatar Marcia Ramos Committed by Douglas Barbosa Alexandre

Review UI text for pipeline error messages

parent dc123787
......@@ -8,15 +8,15 @@ module Ci
# We use a class method here instead of a constant, allowing EE to redefine
# the returned `Hash` more easily.
def self.failure_reasons
{ unknown_failure: 'Unknown pipeline failure!',
config_error: 'CI/CD YAML configuration error!',
external_validation_failure: 'External pipeline validation failed!',
activity_limit_exceeded: 'Pipeline activity limit exceeded!',
size_limit_exceeded: 'Pipeline size limit exceeded!',
job_activity_limit_exceeded: 'Pipeline job activity limit exceeded!',
deployments_limit_exceeded: 'Pipeline deployments limit exceeded!',
project_deleted: 'The associated project was deleted',
user_blocked: 'The user who created this pipeline is blocked' }
{ unknown_failure: 'The reason for the pipeline failure is unknown.',
config_error: 'The pipeline failed due to an error on the CI/CD configuration file.',
external_validation_failure: 'The external pipeline validation failed.',
activity_limit_exceeded: 'The pipeline activity limit was exceeded.',
size_limit_exceeded: 'The pipeline size limit was exceeded.',
job_activity_limit_exceeded: 'The pipeline job activity limit was exceeded.',
deployments_limit_exceeded: 'The pipeline deployments limit was exceeded.',
project_deleted: 'The project associated with this pipeline was deleted.',
user_blocked: 'The user who created this pipeline is blocked.' }
end
presents :pipeline
......
---
title: Review UI text for pipeline error messages
merge_request: 60018
author:
type: other
......@@ -14,7 +14,7 @@ RSpec.describe Ci::PipelinePresenter do
pipeline.failure_reason = :activity_limit_exceeded
expect(presenter.failure_reason)
.to eq 'Pipeline activity limit exceeded!'
.to eq 'The pipeline activity limit was exceeded.'
end
end
......
......@@ -155,7 +155,7 @@ RSpec.describe Ci::PipelineEntity do
it 'has a correct failure reason' do
expect(subject[:failure_reason])
.to eq 'CI/CD YAML configuration error!'
.to eq 'The pipeline failed due to an error on the CI/CD configuration file.'
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