summaryrefslogtreecommitdiff
path: root/spec/javascripts/pipelines
diff options
context:
space:
mode:
authorShah El-Rahman <selrahman@gitlab.com>2018-02-13 22:16:36 -0600
committerShah El-Rahman <selrahman@gitlab.com>2018-02-16 11:00:43 -0600
commite887e858716738c937473776f94d0686c628b2c6 (patch)
treec8348c4e6d379b9a75a851aa6b2bf13887a3f121 /spec/javascripts/pipelines
parent46d59a5d24c0cdbfab42587426dba3ab7b85be03 (diff)
downloadgitlab-ce-e887e858716738c937473776f94d0686c628b2c6.tar.gz
Remove use of callback in pipeline stop/retry modals
Make changes to names of events and variables Combine stop and retry modals into 1 Fix lint issues Add comment about usage of eventHub instead of props
Diffstat (limited to 'spec/javascripts/pipelines')
-rw-r--r--spec/javascripts/pipelines/async_button_spec.js11
1 files changed, 7 insertions, 4 deletions
diff --git a/spec/javascripts/pipelines/async_button_spec.js b/spec/javascripts/pipelines/async_button_spec.js
index 8ce33d410a7..e0ea3649646 100644
--- a/spec/javascripts/pipelines/async_button_spec.js
+++ b/spec/javascripts/pipelines/async_button_spec.js
@@ -15,7 +15,8 @@ describe('Pipelines Async Button', () => {
title: 'Foo',
icon: 'repeat',
cssClass: 'bar',
- id: 123,
+ pipelineId: 123,
+ type: 'explode',
},
}).$mount();
});
@@ -39,8 +40,9 @@ describe('Pipelines Async Button', () => {
describe('With confirm dialog', () => {
it('should call the service when confimation is positive', () => {
- eventHub.$on('actionConfirmationModal', (data) => {
- expect(data.id).toEqual(123);
+ eventHub.$on('openConfirmationModal', (data) => {
+ expect(data.pipelineId).toEqual(123);
+ expect(data.type).toEqual('explode');
});
component = new AsyncButtonComponent({
@@ -49,7 +51,8 @@ describe('Pipelines Async Button', () => {
title: 'Foo',
icon: 'fa fa-foo',
cssClass: 'bar',
- id: 123,
+ pipelineId: 123,
+ type: 'explode',
},
}).$mount();