aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorFuwn <[email protected]>2024-06-19 07:13:56 +0000
committerFuwn <[email protected]>2024-06-19 07:13:56 +0000
commit49898e1c1214470e2684e661b558ee198fba18f0 (patch)
treed8f7f96f5604aa028fa246919bc98ce3c8ae690d /tests
parentdeps(rustc): bump rust toolchain (diff)
downloadgerm-49898e1c1214470e2684e661b558ee198fba18f0.tar.xz
germ-49898e1c1214470e2684e661b558ee198fba18f0.zip
feat: single Node gemtext content conversion
Diffstat (limited to 'tests')
-rw-r--r--tests/ast.rs9
1 files changed, 9 insertions, 0 deletions
diff --git a/tests/ast.rs b/tests/ast.rs
index 6d1f545..9bb7fce 100644
--- a/tests/ast.rs
+++ b/tests/ast.rs
@@ -101,4 +101,13 @@ That was a link without text."#;
format!("{}\n", EXAMPLE_GEMTEXT),
);
}
+
+ #[test]
+ fn gemtext_to_ast_then_node_to_ast_to_gemtext() {
+ assert_eq!(
+ Ast::from_nodes(germ::gemini_to_ast!("=> / Home\n").inner().to_vec())
+ .to_gemtext(),
+ "=> / Home\n"
+ );
+ }
}