From 3e81f08107c7d35f3b10abcd3c0151103d5e31ff Mon Sep 17 00:00:00 2001 From: Hendrik Liebau Date: Wed, 29 Mar 2017 09:52:52 +0200 Subject: [PATCH] add single-line object destructuring test case --- tests/cases/fourslash/formattingInDestructuring3.ts | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/tests/cases/fourslash/formattingInDestructuring3.ts b/tests/cases/fourslash/formattingInDestructuring3.ts index 6162ce5ea05..c573f9ba8d8 100644 --- a/tests/cases/fourslash/formattingInDestructuring3.ts +++ b/tests/cases/fourslash/formattingInDestructuring3.ts @@ -3,7 +3,8 @@ /////*1*/const { /////*2*/ a, /////*3*/ b, -/////*4*/} = { a: 1, b: 2 }; +/////*4*/} = {a: 1, b: 2}; +/////*5*/const {a: c} = {a: 1, b: 2}; format.document(); @@ -14,4 +15,6 @@ verify.currentLineContentIs(" a,"); goTo.marker("3"); verify.currentLineContentIs(" b,"); goTo.marker("4"); -verify.currentLineContentIs("} = { a: 1, b: 2 };"); \ No newline at end of file +verify.currentLineContentIs("} = { a: 1, b: 2 };"); +goTo.marker("5"); +verify.currentLineContentIs("const { a: c } = { a: 1, b: 2 };"); \ No newline at end of file