fix and add test

This commit is contained in:
Arthur Ozga 2017-06-22 11:17:38 -07:00
parent 28fce55e1f
commit f9592b6479
2 changed files with 18 additions and 4 deletions

View File

@ -0,0 +1,18 @@
/// <reference path="fourslash.ts"/>
//// if(true) {/*0*/}
//// if(false)/*1*/{
//// }
format.setOption("PlaceOpenBraceOnNewLineForControlBlocks", true);
goTo.marker("0");
edit.insertLine("");
goTo.marker("1");
edit.insertLine("");
verify.currentFileContentIs(
`if (true)
{
}
if (false)
{
}`);

View File

@ -3,12 +3,8 @@
//// if(true)
//// /**/
format.setOption("PlaceOpenBraceOnNewLineForControlBlocks", false);
goTo.marker("");
edit.insert("{");
// TODO: figure out how to get rid of 3 extra spaces on second last line.
verify.currentFileContentIs(
`if (true) {`);