summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJames Edwards-Jones <jamedjo@gmail.com>2017-08-11 20:50:08 +0000
committerJames Edwards-Jones <jamedjo@gmail.com>2017-08-11 20:50:08 +0000
commit9f15028ca1dae5ce0a3c7a429df7d5503e0a6ca2 (patch)
treeaf58ed31be4dd3df745d8ce4fd03b742dd6cb7cf
parentc7ad1f26b42915317e0eea2b5698a3df699e880a (diff)
parentde6e029ee8788ef6f66678097fbfbae27ea2fd5f (diff)
downloadgitlab-ce-9f15028ca1dae5ce0a3c7a429df7d5503e0a6ca2.tar.gz
Merge branch 'fix-jenkins-error' into '9-4-stable-patch-5'
Fix displaying specific error message when Jenkins test fails See merge request !13510
-rw-r--r--app/assets/javascripts/integrations/integration_settings_form.js2
-rw-r--r--spec/javascripts/integrations/integration_settings_form_spec.js4
2 files changed, 3 insertions, 3 deletions
diff --git a/app/assets/javascripts/integrations/integration_settings_form.js b/app/assets/javascripts/integrations/integration_settings_form.js
index ddd3a6aab99..cf1e6a14725 100644
--- a/app/assets/javascripts/integrations/integration_settings_form.js
+++ b/app/assets/javascripts/integrations/integration_settings_form.js
@@ -102,7 +102,7 @@ export default class IntegrationSettingsForm {
})
.done((res) => {
if (res.error) {
- new Flash(res.message, null, null, {
+ new Flash(`${res.message} ${res.service_response}`, null, null, {
title: 'Save anyway',
clickHandler: (e) => {
e.preventDefault();
diff --git a/spec/javascripts/integrations/integration_settings_form_spec.js b/spec/javascripts/integrations/integration_settings_form_spec.js
index 45909d4e70e..3daeb91b1e2 100644
--- a/spec/javascripts/integrations/integration_settings_form_spec.js
+++ b/spec/javascripts/integrations/integration_settings_form_spec.js
@@ -135,10 +135,10 @@ describe('IntegrationSettingsForm', () => {
integrationSettingsForm.testSettings(formData);
- deferred.resolve({ error: true, message: errorMessage });
+ deferred.resolve({ error: true, message: errorMessage, service_response: 'some error' });
const $flashContainer = $('.flash-container');
- expect($flashContainer.find('.flash-text').text()).toEqual(errorMessage);
+ expect($flashContainer.find('.flash-text').text()).toEqual('Test failed. some error');
expect($flashContainer.find('.flash-action')).toBeDefined();
expect($flashContainer.find('.flash-action').text()).toEqual('Save anyway');
});