mirror of
https://github.com/microsoft/vscode.git
synced 2026-04-23 10:08:49 +01:00
Properly handle links with title
This commit is contained in:
@@ -65,6 +65,14 @@ suite('markdown.DocumentLinkProvider', () => {
|
||||
}
|
||||
});
|
||||
|
||||
test('Should detect links with title', () => {
|
||||
const links = getLinksForFile('a [b](https://example.com "abc") c');
|
||||
assert.strictEqual(links.length, 1);
|
||||
const [link] = links;
|
||||
assertRangeEqual(link.range, new vscode.Range(0, 6, 0, 25));
|
||||
});
|
||||
|
||||
|
||||
test('Should handle links with balanced parens', () => {
|
||||
{
|
||||
const links = getLinksForFile('a [b](https://example.com/a()c) c');
|
||||
|
||||
Reference in New Issue
Block a user