Skip to content

Commit aa32a5c

Browse files
committed
Fix Function expression type inference in constructor test
1 parent 9f7ff5d commit aa32a5c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

test/unit/assignments/functionExpressionTypeInference.spec.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -335,9 +335,9 @@ test.each([
335335
const code = `
336336
class C {
337337
result: string;
338-
constructor(fn: (s: string) => string) { this.result = fn("foo"); }
338+
constructor(fn: ${funcType}) { this.result = fn("foo"); }
339339
}
340-
const c = new C(s => s);
340+
const c = new C(${funcExp});
341341
return c.result;
342342
`;
343343
expect(util.transpileAndExecute(code)).toBe("foo");

0 commit comments

Comments
 (0)