Add regular link tests for all the types.

This commit is contained in:
Tom Alexander 2023-10-06 16:51:25 -04:00
parent 65df18171a
commit 448902bb05
Signed by: talexander
GPG Key ID: D3A179C9A53C0EDE
8 changed files with 15 additions and 0 deletions

View File

@ -0,0 +1 @@
[[(foo)]]

View File

@ -0,0 +1 @@
[[#foo]]

View File

@ -0,0 +1 @@
[[file:simple.org]]

View File

@ -0,0 +1 @@
[[elisp.org]]

View File

@ -0,0 +1 @@
[[id:83986bdf-987c-465d-8851-44cb4c02a86c]]

View File

@ -0,0 +1 @@
[[shell:foo]]

View File

@ -46,6 +46,9 @@ fn regular_link_without_description<'b, 'g, 'r, 's>(
remaining,
RegularLink {
source: source.into(),
link_type: todo!(),
path: todo!(),
raw_link: todo!(),
},
))
}
@ -67,6 +70,9 @@ fn regular_link_with_description<'b, 'g, 'r, 's>(
remaining,
RegularLink {
source: source.into(),
link_type: todo!(),
path: todo!(),
raw_link: todo!(),
},
))
}

View File

@ -77,6 +77,9 @@ pub struct PlainText<'s> {
#[derive(Debug, PartialEq)]
pub struct RegularLink<'s> {
pub source: &'s str,
pub link_type: &'s str,
pub path: &'s str,
pub raw_link: &'s str,
}
#[derive(Debug, PartialEq)]