diff options
author | Harry Kiselev <harry.kiselev@gmail.com> | 2018-12-27 16:58:40 +0300 |
---|---|---|
committer | Harry Kiselev <harry.kiselev@gmail.com> | 2018-12-27 17:40:50 +0300 |
commit | 8a7a9506a1f2fec0995aa15a1da12de8dbbf4eb8 (patch) | |
tree | f39ac38c50ab5d06cea023133b22d24781d04719 /spec/javascripts | |
parent | c01444a79bc1d1dc1576b1d1e71680b27199f48d (diff) |
Move merge request collaboration message into a constant.
Diffstat (limited to 'spec/javascripts')
-rw-r--r-- | spec/javascripts/vue_mr_widget/mr_widget_options_spec.js | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/spec/javascripts/vue_mr_widget/mr_widget_options_spec.js b/spec/javascripts/vue_mr_widget/mr_widget_options_spec.js index 47198d069ee..99b80df766a 100644 --- a/spec/javascripts/vue_mr_widget/mr_widget_options_spec.js +++ b/spec/javascripts/vue_mr_widget/mr_widget_options_spec.js @@ -18,6 +18,8 @@ describe('mrWidgetOptions', () => { let vm; let MrWidgetOptions; + const COLLABORATION_MESSAGE = 'Allows commits from members who can merge to the target branch'; + beforeEach(() => { // Prevent component mounting delete mrWidgetOptions.el; @@ -146,7 +148,7 @@ describe('mrWidgetOptions', () => { }); it('should render collaboration status', () => { - expect(vm.$el.textContent).toContain('Allows commits from members'); + expect(vm.$el.textContent).toContain(COLLABORATION_MESSAGE); }); }); @@ -157,7 +159,7 @@ describe('mrWidgetOptions', () => { }); it('should not render collaboration status', () => { - expect(vm.$el.textContent).not.toContain('Allows commits from members'); + expect(vm.$el.textContent).not.toContain(COLLABORATION_MESSAGE); }); }); }); @@ -174,7 +176,7 @@ describe('mrWidgetOptions', () => { }); it('should not render collaboration status', () => { - expect(vm.$el.textContent).not.toContain('Allows commits from members'); + expect(vm.$el.textContent).not.toContain(COLLABORATION_MESSAGE); }); }); }); |