2019-05-12 22:14:18 +02:00
|
|
|
/// <reference path="fourslash.ts" />
|
|
|
|
|
|
|
|
//// type A = "a/b" | "b/a";
|
2020-04-02 02:58:16 +02:00
|
|
|
//// const a: A = "[|a/*1*/|]";
|
2019-05-12 22:14:18 +02:00
|
|
|
////
|
|
|
|
//// type B = "a@b" | "b@a";
|
2020-04-02 02:58:16 +02:00
|
|
|
//// const a: B = "[|a@/*2*/|]";
|
2019-05-12 22:14:18 +02:00
|
|
|
////
|
|
|
|
//// type C = "a.b" | "b.a";
|
2020-04-02 02:58:16 +02:00
|
|
|
//// const c: C = "[|a./*3*/|]";
|
2019-05-12 22:14:18 +02:00
|
|
|
////
|
|
|
|
//// type D = "a'b" | "b'a";
|
2020-04-02 02:58:16 +02:00
|
|
|
//// const d: D = "[|a'/*4*/|]";
|
2019-05-12 22:14:18 +02:00
|
|
|
////
|
|
|
|
//// type E = "a`b" | "b`a";
|
2020-04-02 02:58:16 +02:00
|
|
|
//// const e: E = "[|a`/*5*/|]";
|
2019-05-12 22:14:18 +02:00
|
|
|
////
|
|
|
|
//// type F = 'a"b' | 'b"a';
|
2020-04-02 02:58:16 +02:00
|
|
|
//// const f: F = '[|a"/*6*/|]';
|
2019-05-12 22:14:18 +02:00
|
|
|
////
|
|
|
|
//// type G = "a<b" | "b<a";
|
2020-04-02 02:58:16 +02:00
|
|
|
//// const g: G = '[|a</*7*/|]';
|
2019-05-12 22:14:18 +02:00
|
|
|
|
2020-04-02 02:58:16 +02:00
|
|
|
verify.completions({ marker: '1', exact: [
|
|
|
|
{ name: "a/b", replacementSpan: test.ranges()[0] },
|
|
|
|
{ name: "b/a", replacementSpan: test.ranges()[0] }
|
|
|
|
], triggerCharacter: "/" });
|
|
|
|
verify.completions({ marker: "2", exact: [
|
|
|
|
{ name: "a@b", replacementSpan: test.ranges()[1] },
|
|
|
|
{ name: "b@a", replacementSpan: test.ranges()[1] }
|
|
|
|
], triggerCharacter: "@" });
|
|
|
|
verify.completions({ marker: "3", exact: [
|
|
|
|
{ name: "a.b", replacementSpan: test.ranges()[2] },
|
|
|
|
{ name: "b.a", replacementSpan: test.ranges()[2] }
|
|
|
|
], triggerCharacter: "." });
|
|
|
|
verify.completions({ marker: "4", exact: [
|
|
|
|
{ name: "a'b", replacementSpan: test.ranges()[3] },
|
|
|
|
{ name: "b'a", replacementSpan: test.ranges()[3] }
|
|
|
|
], triggerCharacter: "'" });
|
|
|
|
verify.completions({ marker: "5", exact: [
|
|
|
|
{ name: "a`b", replacementSpan: test.ranges()[4] },
|
|
|
|
{ name: "b`a", replacementSpan: test.ranges()[4] }
|
|
|
|
], triggerCharacter: "`" });
|
|
|
|
verify.completions({ marker: "6", exact: [
|
|
|
|
{ name: 'a"b', replacementSpan: test.ranges()[5] },
|
|
|
|
{ name: 'b"a', replacementSpan: test.ranges()[5] }
|
|
|
|
], triggerCharacter: '"' });
|
|
|
|
verify.completions({ marker: "7", exact: [
|
|
|
|
{ name: 'a<b', replacementSpan: test.ranges()[6] },
|
|
|
|
{ name: 'b<a', replacementSpan: test.ranges()[6] }
|
|
|
|
], triggerCharacter: '<' });
|