Add fields displayed in modal to test

This commit is contained in:
mfluharty 2019-03-06 14:28:36 -07:00
parent d6a9cd5d04
commit b5a3004e2f
No known key found for this signature in database
GPG key ID: 6FDA03A308D239E8

View file

@ -195,8 +195,10 @@ describe('Pipelines Table Row', () => {
it('emits `openConfirmationModal` event when cancel button is clicked and toggles loading', () => {
eventHub.$once('openConfirmationModal', data => {
const { id, ref, commit } = pipeline;
expect(data.endpoint).toEqual('/cancel');
expect(data.pipeline.id).toEqual(pipeline.id);
expect(data.pipeline).toEqual(jasmine.objectContaining({ id, ref, commit }));
});
component.$el.querySelector('.js-pipelines-cancel-button').click();