Commit e2575def authored by Phil Hughes's avatar Phil Hughes

Fixed eslint

parent 9cd53cd8
/* global Vue */ /* global Vue */
/* global boardsMockInterceptor */
/* global BoardService */
/* global List */
/* global listObj */
import boardNewIssue from '~/boards/components/board_new_issue'; import boardNewIssue from '~/boards/components/board_new_issue';
...@@ -6,7 +10,7 @@ require('~/boards/models/list'); ...@@ -6,7 +10,7 @@ require('~/boards/models/list');
require('./mock_data'); require('./mock_data');
require('es6-promise').polyfill(); require('es6-promise').polyfill();
fdescribe('Issue boards new issue form', () => { describe('Issue boards new issue form', () => {
let vm; let vm;
let list; let list;
const promiseReturn = { const promiseReturn = {
...@@ -31,15 +35,13 @@ fdescribe('Issue boards new issue form', () => { ...@@ -31,15 +35,13 @@ fdescribe('Issue boards new issue form', () => {
setTimeout(() => { setTimeout(() => {
list = new List(listObj); list = new List(listObj);
spyOn(gl.boardService, 'newIssue').and.callFake(() => { spyOn(gl.boardService, 'newIssue').and.callFake(() => new Promise((resolve, reject) => {
return new Promise((resolve, reject) => { if (vm.title === 'error') {
if (vm.title === 'error') { reject();
reject(); } else {
} else { resolve(promiseReturn);
resolve(promiseReturn); }
} }));
});
});
vm = new BoardNewIssueComp({ vm = new BoardNewIssueComp({
propsData: { propsData: {
...@@ -101,7 +103,7 @@ fdescribe('Issue boards new issue form', () => { ...@@ -101,7 +103,7 @@ fdescribe('Issue boards new issue form', () => {
}); });
it('enables button after submit', (done) => { it('enables button after submit', (done) => {
vm.title= 'submit issue'; vm.title = 'submit issue';
setTimeout(() => { setTimeout(() => {
submitIssue(); submitIssue();
......
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