newTextSearchResult('long text very long text foo',newOneLineRange(5,25,28),previewOptions1),
<ITextSearchResult>{
preview:{
text:'long text foo',
match:newOneLineRange(0,10,13)
},
range:newOneLineRange(5,25,28)
});
});
test('trailing',()=>{
assert.deepEqual(
newTextSearchResult('foo long text very long text long text very long text long text very long text long text very long text long text very long text',newOneLineRange(5,0,3),previewOptions1),
<ITextSearchResult>{
preview:{
text:'foo long text very long text long text very long text long text very long text long text very long t',
match:newOneLineRange(0,0,3)
},
range:newOneLineRange(5,0,3)
});
});
test('middle',()=>{
assert.deepEqual(
newTextSearchResult('long text very long text long foo text very long text long text very long text long text very long text long text very long text',newOneLineRange(5,30,33),previewOptions1),
<ITextSearchResult>{
preview:{
text:'text long foo text very long text long text very long text long text very long text long text very l',