summaryrefslogtreecommitdiffhomepage
path: root/lib/prog
diff options
context:
space:
mode:
authorjao <jao@gnu.org>2026-04-15 11:27:43 +0100
committerjao <jao@gnu.org>2026-04-15 11:29:33 +0100
commit1fbccb6e3dde6fd0a564cd60dd40fa502fe4484f (patch)
treebbae20849517c91d7245ee2d641110b8f8456a13 /lib/prog
parent423ed1c28d147558ed0ceaa43be2f866f5cb5be7 (diff)
downloadelibs-1fbccb6e3dde6fd0a564cd60dd40fa502fe4484f.tar.gz
elibs-1fbccb6e3dde6fd0a564cd60dd40fa502fe4484f.tar.bz2
rust wee utils
Diffstat (limited to 'lib/prog')
-rw-r--r--lib/prog/jao-rust.el5
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/prog/jao-rust.el b/lib/prog/jao-rust.el
index 436de00..5e20744 100644
--- a/lib/prog/jao-rust.el
+++ b/lib/prog/jao-rust.el
@@ -62,7 +62,10 @@
(interactive)
(or (re-search-forward jao-rust--tests-mod-rx nil t)
(re-search-backward jao-rust--tests-mod-rx nil t)
- (message "No tests module")))
+ (when (y-or-n-p "No tests module. Add it?")
+ (goto-char (point-max))
+ (insert "\n#[cfg(test)]\nmod tests {\n\n}")
+ (forward-line -1))))
(defun jao-rust-test-current ()
(interactive)