format jest calls like regular calls (#5011)

master
Eric Sakmar 2018-09-03 09:15:23 -04:00 committed by Lucas Duailibe
parent 0c7c1bfde4
commit 6288704c41
3 changed files with 61 additions and 4 deletions

View File

@ -5800,10 +5800,7 @@ function isTestCall(n, parent) {
}
if (isUnitTestSetUp(n)) {
return (
isFunctionOrArrowExpression(n.arguments[0].type) ||
isAngularTestWrapper(n.arguments[0])
);
return isAngularTestWrapper(n.arguments[0]);
}
} else if (n.arguments.length === 2) {
if (

View File

@ -5,10 +5,22 @@ beforeEach(async(() => {
// code
}));
beforeEach(done =>
foo()
.bar()
.bar(),
);
afterAll(async(() => {
console.log('Hello');
}));
afterAll(done =>
foo()
.bar()
.bar(),
);
it('should create the app', async(() => {
//code
}));
@ -28,10 +40,22 @@ beforeEach(async(() => {
// code
}));
beforeEach(done =>
foo()
.bar()
.bar()
);
afterAll(async(() => {
console.log("Hello");
}));
afterAll(done =>
foo()
.bar()
.bar()
);
it("should create the app", async(() => {
//code
}));
@ -56,10 +80,22 @@ beforeEach(async(() => {
// code
}));
beforeEach(done =>
foo()
.bar()
.bar(),
);
afterAll(async(() => {
console.log('Hello');
}));
afterAll(done =>
foo()
.bar()
.bar(),
);
it('should create the app', async(() => {
//code
}));
@ -79,10 +115,22 @@ beforeEach(async(() => {
// code
}));
beforeEach((done) =>
foo()
.bar()
.bar()
);
afterAll(async(() => {
console.log("Hello");
}));
afterAll((done) =>
foo()
.bar()
.bar()
);
it("should create the app", async(() => {
//code
}));

View File

@ -2,10 +2,22 @@ beforeEach(async(() => {
// code
}));
beforeEach(done =>
foo()
.bar()
.bar(),
);
afterAll(async(() => {
console.log('Hello');
}));
afterAll(done =>
foo()
.bar()
.bar(),
);
it('should create the app', async(() => {
//code
}));