From c6a2fae774117b3d7d5cd2fa7f6230e7f0018a66 Mon Sep 17 00:00:00 2001 From: fdai7381 Date: Tue, 17 Jan 2023 10:03:12 +0100 Subject: [PATCH] test: add parse line test --- src/parse.rs | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/src/parse.rs b/src/parse.rs index e6e3765..4d07452 100644 --- a/src/parse.rs +++ b/src/parse.rs @@ -23,7 +23,15 @@ mod tests { fn test_tokenize() { assert_eq!( tokenize("test arg1 arg2 arg3"), - ["test", "arg1", "arg2", "arg3"] + vec!["test", "arg1", "arg2", "arg3"] + ); + } + + #[test] + fn test_parse_line() { + assert_eq!( + parse_line("test arg1 arg2 arg3"), + ("test", vec!["arg1", "arg2", "arg3"]) ); } }