From 73d8609565b808ac73df5ac34e6d4f7f23c25ad6 Mon Sep 17 00:00:00 2001 From: Titus Wormer Date: Tue, 11 Oct 2022 15:45:50 +0200 Subject: Refactor to use a bunch of `into` --- tests/code_fenced.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'tests/code_fenced.rs') diff --git a/tests/code_fenced.rs b/tests/code_fenced.rs index 6da38a9..c41bd43 100644 --- a/tests/code_fenced.rs +++ b/tests/code_fenced.rs @@ -287,9 +287,9 @@ fn code_fenced() -> Result<(), String> { )?, Node::Root(Root { children: vec![Node::Code(Code { - lang: Some("js".to_string()), - meta: Some("extra".to_string()), - value: "console.log(1)\nconsole.log(2)".to_string(), + lang: Some("js".into()), + meta: Some("extra".into()), + value: "console.log(1)\nconsole.log(2)".into(), position: Some(Position::new(1, 1, 0, 4, 4, 45)) })], position: Some(Position::new(1, 1, 0, 4, 4, 45)) @@ -303,7 +303,7 @@ fn code_fenced() -> Result<(), String> { children: vec![Node::Code(Code { lang: None, meta: None, - value: "asd".to_string(), + value: "asd".into(), position: Some(Position::new(1, 1, 0, 2, 4, 7)) })], position: Some(Position::new(1, 1, 0, 2, 4, 7)) -- cgit