diff options
Diffstat (limited to '.emacs.d/snippets/rust-mode/testmod')
| -rw-r--r-- | .emacs.d/snippets/rust-mode/testmod | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/.emacs.d/snippets/rust-mode/testmod b/.emacs.d/snippets/rust-mode/testmod new file mode 100644 index 0000000..d3494b7 --- /dev/null +++ b/.emacs.d/snippets/rust-mode/testmod | |||
| @@ -0,0 +1,13 @@ | |||
| 1 | # -*- mode: snippet -*- | ||
| 2 | # name: test module | ||
| 3 | # key: testmod | ||
| 4 | # -- | ||
| 5 | #[cfg(test)] | ||
| 6 | mod ${1:tests} { | ||
| 7 | use super::*; | ||
| 8 | |||
| 9 | #[test] | ||
| 10 | fn ${2:test_name}() { | ||
| 11 | $0 | ||
| 12 | } | ||
| 13 | } | ||
