Skip to content

Commit 9de5680

Browse files
committed
Updated additional formatting conditionals test cases
1 parent e1adde6 commit 9de5680

File tree

2 files changed

+43
-14
lines changed

2 files changed

+43
-14
lines changed
Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
/// <reference path='fourslash.ts' />
2+
3+
////var v =
4+
/////*1*/0 ? 1 :
5+
/////*2*/2 ? 3 :
6+
/////*3*/4;
7+
8+
////var x =
9+
/////*4*/a ? b :
10+
/////*5*/c ? d :
11+
/////*6*/e;
12+
13+
////var opacity =
14+
/////*7*/depth == 0 ? 1 :
15+
/////*8*/depth == 1 ? .7 :
16+
/////*9*/depth == 2 ? .5 :
17+
/////*10*/depth == 3 ? .4 : .3;
18+
19+
format.document();
20+
goTo.marker('1');
21+
verify.indentationIs(4);
22+
goTo.marker('2');
23+
verify.indentationIs(4);
24+
goTo.marker('3');
25+
verify.indentationIs(4);
26+
27+
format.document();
28+
goTo.marker('4');
29+
verify.indentationIs(4);
30+
goTo.marker('5');
31+
verify.indentationIs(4);
32+
goTo.marker('6');
33+
verify.indentationIs(4);
34+
35+
format.document();
36+
goTo.marker('7');
37+
verify.indentationIs(4);
38+
goTo.marker('8');
39+
verify.indentationIs(4);
40+
goTo.marker('9');
41+
verify.indentationIs(4);
42+
goTo.marker('10');
43+
verify.indentationIs(4);

tests/cases/fourslash/formattingTernaryOperator.ts

Lines changed: 0 additions & 14 deletions
This file was deleted.

0 commit comments

Comments
 (0)