blob: 8a114f90ebcfbd55fcd6018c8367718353f60d53 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
use askama::Template;
macro_rules! hello {
() => {
"world"
};
}
#[derive(Template)]
#[template(path = "rust-macros.html")]
struct RustMacrosTemplate {}
#[test]
fn main() {
let template = RustMacrosTemplate {};
assert_eq!("Hello, world!", template.render().unwrap());
}
|