@@ -63,6 +63,9 @@ this is some text
63
63
64
64
const string TextNode = "this is some text" ;
65
65
66
+ const string TextNodeWithWhitespace = @" this is some text
67
+ " ;
68
+
66
69
const string AttributesFoo = @"hello=""hi"" goodbye=""bye""" ;
67
70
68
71
const string AttributeHello = @"hello=""hi""" ;
@@ -91,16 +94,19 @@ this is some text
91
94
92
95
const string CommentBar = @"<!--another comment-->" ;
93
96
97
+ const string CommentBarWithWhitespace = @" <!--another comment-->
98
+ " ;
99
+
94
100
//args are document, line, col, then the expected sequence of expansions
95
101
[ Test ]
96
102
[ TestCase ( Document , 1 , 2 , CommentDoc ) ]
97
103
[ TestCase ( Document , 3 , 2 , "foo" , ElementFoo , ElementWithBodyFoo ) ]
98
104
[ TestCase ( Document , 3 , 3 , "foo" , ElementFoo , ElementWithBodyFoo ) ]
99
105
[ TestCase ( Document , 3 , 15 , "hi" , AttributeHello , AttributesFoo , ElementFoo , ElementWithBodyFoo ) ]
100
106
[ TestCase ( Document , 3 , 7 , "hello" , AttributeHello , AttributesFoo , ElementFoo , ElementWithBodyFoo ) ]
101
- [ TestCase ( Document , 4 , 7 , TextNode , BodyFoo , ElementWithBodyFoo ) ]
107
+ [ TestCase ( Document , 4 , 7 , "is" , TextNode , TextNodeWithWhitespace , BodyFoo , ElementWithBodyFoo ) ]
102
108
[ TestCase ( Document , 5 , 22 , "done" , AttributeThing , ElementBaz , BodyBar , ElementWithBodyBar , BodyFoo , ElementWithBodyFoo ) ]
103
- [ TestCase ( Document , 6 , 12 , CommentBar , BodyBar , ElementWithBodyBar , BodyFoo , ElementWithBodyFoo ) ]
109
+ [ TestCase ( Document , 6 , 12 , CommentBar , CommentBarWithWhitespace , BodyBar , ElementWithBodyBar , BodyFoo , ElementWithBodyFoo ) ]
104
110
public async Task TestExpandShrink ( object [ ] args )
105
111
{
106
112
var buffer = CreateTextBuffer ( ( string ) args [ 0 ] ) ;
0 commit comments