mirror of
https://github.com/microsoft/TypeScript.git
synced 2025-11-18 17:21:48 +00:00
Added more tests.
This commit is contained in:
@@ -0,0 +1,12 @@
|
||||
/// <reference path='fourslash.ts'/>
|
||||
|
||||
////interface I {
|
||||
//// property1: number;
|
||||
//// property2: string;
|
||||
////}
|
||||
////
|
||||
////var foo: I;
|
||||
////var { property1, property2, /**/ } = foo;
|
||||
|
||||
goTo.marker();
|
||||
verify.completionListIsEmpty();
|
||||
@@ -0,0 +1,18 @@
|
||||
/// <reference path='fourslash.ts'/>
|
||||
|
||||
////interface I {
|
||||
//// propertyOfI_1: number;
|
||||
//// propertyOfI_2: string;
|
||||
////}
|
||||
////interface J {
|
||||
//// property1: I;
|
||||
//// property2: string;
|
||||
////}
|
||||
////
|
||||
////var foo: J;
|
||||
////var { property1: { /**/ } } = foo;
|
||||
|
||||
goTo.marker();
|
||||
verify.completionListContains("propertyOfI_1");
|
||||
verify.completionListContains("propertyOfI_2");
|
||||
verify.not.completionListContains("property2");
|
||||
@@ -0,0 +1,18 @@
|
||||
/// <reference path='fourslash.ts'/>
|
||||
|
||||
////interface I {
|
||||
//// propertyOfI_1: number;
|
||||
//// propertyOfI_2: string;
|
||||
////}
|
||||
////interface J {
|
||||
//// property1: I;
|
||||
//// property2: string;
|
||||
////}
|
||||
////
|
||||
////var foo: J;
|
||||
////var { property1: { propertyOfI_1, /**/ } } = foo;
|
||||
|
||||
goTo.marker();
|
||||
verify.completionListContains("propertyOfI_2");
|
||||
verify.not.completionListContains("propertyOfI_1");
|
||||
verify.not.completionListContains("property2");
|
||||
@@ -0,0 +1,19 @@
|
||||
/// <reference path='fourslash.ts'/>
|
||||
|
||||
////interface I {
|
||||
//// propertyOfI_1: number;
|
||||
//// propertyOfI_2: string;
|
||||
////}
|
||||
////interface J {
|
||||
//// property1: I;
|
||||
//// property2: string;
|
||||
////}
|
||||
////
|
||||
////var foo: J;
|
||||
////var { property1: { propertyOfI_1, }, /**/ } = foo;
|
||||
|
||||
goTo.marker();
|
||||
verify.completionListContains("property2");
|
||||
verify.not.completionListContains("property1");
|
||||
verify.not.completionListContains("propertyOfI_2");
|
||||
verify.not.completionListContains("propertyOfI_1");
|
||||
Reference in New Issue
Block a user