mirror of
https://github.com/microsoft/TypeScript.git
synced 2026-07-01 02:02:45 -05:00
Update tests
This commit is contained in:
7
tests/cases/fourslash/tsxCompletion11.ts
Normal file
7
tests/cases/fourslash/tsxCompletion11.ts
Normal file
@@ -0,0 +1,7 @@
|
||||
/// <reference path='fourslash.ts' />
|
||||
|
||||
//@Filename: file.tsx
|
||||
//// var x1 = </**/
|
||||
|
||||
goTo.marker();
|
||||
verify.memberListCount(0);
|
||||
8
tests/cases/fourslash/tsxCompletion12.ts
Normal file
8
tests/cases/fourslash/tsxCompletion12.ts
Normal file
@@ -0,0 +1,8 @@
|
||||
/// <reference path='fourslash.ts' />
|
||||
|
||||
//@Filename: file.tsx
|
||||
//// var x1 = <div><//**/
|
||||
|
||||
goTo.marker();
|
||||
verify.memberListCount(1);
|
||||
verify.completionListContains('div');
|
||||
8
tests/cases/fourslash/tsxCompletion13.ts
Normal file
8
tests/cases/fourslash/tsxCompletion13.ts
Normal file
@@ -0,0 +1,8 @@
|
||||
/// <reference path='fourslash.ts' />
|
||||
|
||||
//@Filename: file.tsx
|
||||
//// class MyElement {}
|
||||
//// var x1 = <My/**/
|
||||
|
||||
goTo.marker("");
|
||||
verify.memberListCount(0);
|
||||
8
tests/cases/fourslash/tsxCompletion14.ts
Normal file
8
tests/cases/fourslash/tsxCompletion14.ts
Normal file
@@ -0,0 +1,8 @@
|
||||
/// <reference path='fourslash.ts' />
|
||||
|
||||
//@Filename: file.tsx
|
||||
//// class MyElement {}
|
||||
//// var x1 = <My/**/
|
||||
|
||||
goTo.marker("");
|
||||
verify.memberListCount(0);
|
||||
9
tests/cases/fourslash/tsxCompletion15.ts
Normal file
9
tests/cases/fourslash/tsxCompletion15.ts
Normal file
@@ -0,0 +1,9 @@
|
||||
/// <reference path='fourslash.ts' />
|
||||
|
||||
//@Filename: file.tsx
|
||||
//// class MyElement {}
|
||||
//// var x1 = <MyElement></My/**/
|
||||
|
||||
goTo.marker("");
|
||||
verify.memberListCount(1);
|
||||
verify.completionListContains('MyElement');
|
||||
7
tests/cases/fourslash/tsxCompletion16.ts
Normal file
7
tests/cases/fourslash/tsxCompletion16.ts
Normal file
@@ -0,0 +1,7 @@
|
||||
/// <reference path='fourslash.ts' />
|
||||
|
||||
//@Filename: file.tsx
|
||||
//// var x1 = </**/
|
||||
|
||||
goTo.marker("");
|
||||
verify.memberListCount(0);
|
||||
8
tests/cases/fourslash/tsxCompletion17.ts
Normal file
8
tests/cases/fourslash/tsxCompletion17.ts
Normal file
@@ -0,0 +1,8 @@
|
||||
/// <reference path='fourslash.ts' />
|
||||
|
||||
//@Filename: file.tsx
|
||||
//// var x1 = <MyElement></My/**/
|
||||
|
||||
goTo.marker("");
|
||||
verify.memberListCount(1);
|
||||
verify.completionListContains('MyElement');
|
||||
30
tests/cases/fourslash/tsxCompletion18.ts
Normal file
30
tests/cases/fourslash/tsxCompletion18.ts
Normal file
@@ -0,0 +1,30 @@
|
||||
/// <reference path='fourslash.ts' />
|
||||
|
||||
//@Filename: file.tsx
|
||||
//// var x = <div>
|
||||
//// <h1> </ /*1*/>
|
||||
//// <d/*3*/iv> </ /*4*/>
|
||||
//// <d/*5*/iv> </ /*6*/>
|
||||
//// </ /*2*/>
|
||||
|
||||
goTo.marker("1");
|
||||
verify.memberListCount(1);
|
||||
verify.completionListContains('h1');
|
||||
|
||||
goTo.marker("2");
|
||||
verify.memberListCount(1);
|
||||
verify.completionListContains('div');
|
||||
|
||||
goTo.marker("3");
|
||||
verify.memberListCount(0);
|
||||
|
||||
goTo.marker("4");
|
||||
verify.memberListCount(1);
|
||||
verify.completionListContains('div');
|
||||
|
||||
goTo.marker("5");
|
||||
verify.memberListCount(0);
|
||||
|
||||
goTo.marker("6");
|
||||
verify.memberListCount(1);
|
||||
verify.completionListContains('div');
|
||||
18
tests/cases/fourslash/tsxQuickInfo1.ts
Normal file
18
tests/cases/fourslash/tsxQuickInfo1.ts
Normal file
@@ -0,0 +1,18 @@
|
||||
/// <reference path='fourslash.ts' />
|
||||
|
||||
//@Filename: file.tsx
|
||||
//// var x1 = <di/*1*/v></di/*2*/v>
|
||||
//// class MyElement {}
|
||||
//// var z = <My/*3*/Element></My/*4*/Element>
|
||||
|
||||
goTo.marker("1");
|
||||
verify.quickInfoIs("any", undefined);
|
||||
|
||||
goTo.marker("2");
|
||||
verify.quickInfoIs("any", undefined);;
|
||||
|
||||
goTo.marker("3");
|
||||
verify.quickInfoIs("class MyElement", undefined);;
|
||||
|
||||
goTo.marker("4");
|
||||
verify.quickInfoIs("class MyElement", undefined);;
|
||||
24
tests/cases/fourslash/tsxQuickInfo2.ts
Normal file
24
tests/cases/fourslash/tsxQuickInfo2.ts
Normal file
@@ -0,0 +1,24 @@
|
||||
/// <reference path='fourslash.ts' />
|
||||
|
||||
//@Filename: file.tsx
|
||||
//// declare module JSX {
|
||||
//// interface Element { }
|
||||
//// interface IntrinsicElements {
|
||||
//// div: any
|
||||
//// }
|
||||
//// }
|
||||
//// var x1 = <di/*1*/v></di/*2*/v>
|
||||
//// class MyElement {}
|
||||
//// var z = <My/*3*/Element></My/*4*/Element>
|
||||
|
||||
goTo.marker("1");
|
||||
verify.quickInfoIs("(property) JSX.IntrinsicElements.div: any", undefined);
|
||||
|
||||
goTo.marker("2");
|
||||
verify.quickInfoIs("(property) JSX.IntrinsicElements.div: any", undefined);;
|
||||
|
||||
goTo.marker("3");
|
||||
verify.quickInfoIs("class MyElement", undefined);;
|
||||
|
||||
goTo.marker("4");
|
||||
verify.quickInfoIs("class MyElement", undefined);;
|
||||
Reference in New Issue
Block a user