Skip to content

Commit 010b9b6

Browse files
committed
Enabling more quickInfo tests
1 parent 417cd94 commit 010b9b6

33 files changed

+152
-206
lines changed

tests/cases/fourslash_old/qualifiedName_import-declaration-with-variable-entity-names.ts renamed to tests/cases/fourslash/qualifiedName_import-declaration-with-variable-entity-names.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
////var x = Alpha.[|{| "name" : "mem" |}x|]
1212

1313
goTo.marker('import');
14-
verify.completionListContains('x', 'number');
14+
verify.completionListContains('x', '(var) Alpha.x: number');
1515

1616
var def: FourSlashInterface.Range = test.ranges().filter(range => range.marker.data.name === "def")[0];
1717
var imp: FourSlashInterface.Range = test.ranges().filter(range => range.marker.data.name === "import")[0];

tests/cases/fourslash_old/quickInfoExportAssignmentOfGenericInterface.ts renamed to tests/cases/fourslash/quickInfoExportAssignmentOfGenericInterface.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,4 +13,4 @@
1313

1414
goTo.file("quickInfoExportAssignmentOfGenericInterface_1.ts");
1515
goTo.marker('1');
16-
verify.quickInfoIs("a<a<string>>", undefined, "x", "var");
16+
verify.quickInfoIs("(var) x: a<a<string>>", undefined);

tests/cases/fourslash_old/quickInfoForAliasedGeneric.ts renamed to tests/cases/fourslash/quickInfoForAliasedGeneric.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,11 @@
77
//// }
88
////}
99
////import d = M.N;
10-
////var aa/*1*/: d.C<number>;
11-
////var bb/*2*/: d.D;
10+
////var /*1*/aa: d.C<number>;
11+
////var /*2*/bb: d.D;
1212

1313
goTo.marker('1');
14-
verify.quickInfoIs('M.N.C<number>');
14+
verify.quickInfoIs('(var) aa: d.C<number>');
1515

1616
goTo.marker('2');
17-
verify.quickInfoIs('M.N.D');
17+
verify.quickInfoIs('(var) bb: d.D');

tests/cases/fourslash_old/quickInfoForContextuallyTypedFunctionInReturnStatement.ts renamed to tests/cases/fourslash/quickInfoForContextuallyTypedFunctionInReturnStatement.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,4 +17,4 @@
1717

1818

1919
goTo.marker();
20-
verify.quickInfoIs("number");
20+
verify.quickInfoIs("(parameter) value: number");

tests/cases/fourslash_old/quickInfoForDerivedGenericTypeWithConstructor.ts renamed to tests/cases/fourslash/quickInfoForDerivedGenericTypeWithConstructor.ts

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,11 @@
1010
////class B2<T> extends A<T> {
1111
//// bar() { }
1212
////}
13-
14-
////var b/*1*/: B<number>;
15-
////var b2/*2*/: B<number>;
13+
////var /*1*/b: B<number>;
14+
////var /*2*/b2: B<number>;
1615

1716
goTo.marker('1');
18-
verify.quickInfoIs('B<number>');
17+
verify.quickInfoIs('(var) b: B<number>');
1918

2019
goTo.marker('2');
21-
verify.quickInfoIs('B<number>');
20+
verify.quickInfoIs('(var) b2: B<number>');

tests/cases/fourslash_old/quickInfoForFunctionDeclaration.ts renamed to tests/cases/fourslash/quickInfoForFunctionDeclaration.ts

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,17 +4,15 @@
44
////
55
////function ma/*makeA*/keA<T>(t: T): A<T> { return null; }
66
////
7-
////function f/*f*/<T>(t: T) {
7+
////function /*f*/f<T>(t: T) {
88
//// return makeA(t);
99
////}
1010
////
1111
////var x = f(0);
1212
////var y = makeA(0);
1313

14-
15-
1614
goTo.marker("makeA");
17-
verify.quickInfoIs("<T>(t: T): A<T>", undefined, "makeA", "function");
15+
verify.quickInfoIs("(function) makeA<T>(t: T): A<T>", undefined);
1816

1917
goTo.marker("f");
20-
verify.quickInfoIs("<T>(t: T): A<T>", undefined, "f", "function");
18+
verify.quickInfoIs("(function) f<T>(t: T): A<T>", undefined);

tests/cases/fourslash_old/quickInfoForGenericConstraints1.ts renamed to tests/cases/fourslash/quickInfoForGenericConstraints1.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,6 @@
44
////function foo4<T extends Date>(test: any): any { return null; }
55

66
goTo.marker();
7-
verify.quickInfoIs('T extends Date');
7+
// TODO: formatting type parameter with extends info
8+
//verify.quickInfoIs('parameter) test: T extends Date');
9+
verify.quickInfoIs('(parameter) test: T');

tests/cases/fourslash_old/quickInfoForIndexerResultWithConstraint.ts renamed to tests/cases/fourslash/quickInfoForIndexerResultWithConstraint.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@
66

77
////function other2<T extends Date>(arg: T) {
88
//// var b: { [x: string]: T };
9-
//// var r2/*1*/ = foo(b); // just shows T
9+
//// var /*1*/r2 = foo(b); // just shows T
1010
////}
1111

1212
goTo.marker('1');
13-
verify.quickInfoIs('{ [x: string]: T; }');
13+
verify.quickInfoIs('(local var) r2: {\n [x: string]: T;\n}');

tests/cases/fourslash_old/quickInfoForOverloadOnConst1.ts renamed to tests/cases/fourslash/quickInfoForOverloadOnConst1.ts

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -20,22 +20,22 @@
2020
////c.x1(1, (x/*10*/x) => { return 1; } );
2121

2222
goTo.marker('1');
23-
verify.quickInfoIs("(a: number, callback: (x: 'hi') => number): any");
23+
verify.quickInfoIs("(method) I.x1(a: number, callback: (x: 'hi') => number): any");
2424
goTo.marker('2');
25-
verify.quickInfoIs("(a: number, callback: (x: 'hi') => number): any (+ 0 overload(s))");
25+
verify.quickInfoIs("(method) C.x1(a: number, callback: (x: 'hi') => number): any");
2626
goTo.marker('3');
27-
verify.quickInfoIs("(x: 'hi') => number");
27+
verify.quickInfoIs("(parameter) callback: (x: 'hi') => number");
2828
goTo.marker('4');
29-
verify.quickInfoIs("(a: number, callback: (x: 'hi') => number): any (+ 0 overload(s))");
29+
verify.quickInfoIs("(method) C.x1(a: number, callback: (x: 'hi') => number): any");
3030
goTo.marker('5');
31-
verify.quickInfoIs('(x: string) => number');
31+
verify.quickInfoIs('(parameter) callback: (x: string) => number');
3232
goTo.marker('6');
33-
verify.quickInfoIs('(x: string): number');
33+
verify.quickInfoIs('(local function) callback(x: string): number');
3434
goTo.marker('7');
35-
verify.quickInfoIs("(a: number, callback: (x: 'hi') => number): any (+ 0 overload(s))");
35+
verify.quickInfoIs("(method) C.x1(a: number, callback: (x: 'hi') => number): any");
3636
goTo.marker('8');
37-
verify.quickInfoIs("'hi'");
37+
verify.quickInfoIs("(parameter) xx: 'hi'");
3838
goTo.marker('9');
39-
verify.quickInfoIs("'bye'");
39+
verify.quickInfoIs("(parameter) xx: 'bye'");
4040
goTo.marker('10');
41-
verify.quickInfoIs("'hi'");
41+
verify.quickInfoIs("(parameter) xx: 'hi'");

tests/cases/fourslash_old/quickInfoForTypeofParameter.ts renamed to tests/cases/fourslash/quickInfoForTypeofParameter.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,10 @@
66
////}
77

88
goTo.marker('ref2');
9-
verify.quickInfoIs("string", undefined, "y1", "local var");
9+
verify.quickInfoIs("(local var) y1: string", undefined);
1010

1111
goTo.marker('ref1');
12-
verify.quickInfoIs("string", undefined, "y1", "local var");
12+
verify.quickInfoIs("(local var) y1: string", undefined);
1313

1414
goTo.marker('ref2');
15-
verify.quickInfoIs("string", undefined, "y1", "local var");
15+
verify.quickInfoIs("(local var) y1: string", undefined);

0 commit comments

Comments
 (0)