aboutsummaryrefslogtreecommitdiff
path: root/src/test.rs
diff options
context:
space:
mode:
author魏曹先生 <1992414357@qq.com>2026-06-29 03:11:13 +0800
committer魏曹先生 <1992414357@qq.com>2026-06-29 03:11:13 +0800
commit03003aec99fc00c2a079bad9fb4e721432a6e6f0 (patch)
tree3767548b240447c96e49ebd4519a9ae20d47626e /src/test.rs
parent58307e49e24bbbff55846147d97fbe60054486cc (diff)
feat: add CHANGELOG and simplify tmpl! macro syntax
Introduce a CHANGELOG.md file and update the `tmpl!` macro to use a cleaner syntax with comma-separated key-value pairs instead of the `+=` operator and parentheses-wrapped parameters
Diffstat (limited to 'src/test.rs')
-rw-r--r--src/test.rs8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/test.rs b/src/test.rs
index a5ef801..91407fc 100644
--- a/src/test.rs
+++ b/src/test.rs
@@ -15,12 +15,12 @@ mod tests {
let mut tmpl = Template::from(input);
tmpl_param!(tmpl, func_name = "my_func");
- tmpl!(tmpl += {
+ tmpl!(tmpl,
arms {
- (crate_name = "my"),
- (crate_name = "you")
+ crate_name = "my",
+ crate_name = "you",
}
- });
+ );
let expanded = tmpl.expand().unwrap();
assert_eq!(expanded, expect);