diff options
| author | Aankhen <Aankhen@users.noreply.github.com> | 2017-06-26 16:14:27 +0530 |
|---|---|---|
| committer | Aankhen <Aankhen@users.noreply.github.com> | 2017-07-13 11:46:06 +0530 |
| commit | 72c479bd0d91befe9b2a77636c6b2731163ffcd6 (patch) | |
| tree | 032d13362f28ab6fc7fae2a7f945822bb0c49f45 /rust-mode-tests.el | |
| parent | 60a1f36f4111e825d20d9c3aed561981c470806a (diff) | |
| download | rust-mode-72c479bd0d91befe9b2a77636c6b2731163ffcd6.tar.gz | |
Add `rust-run-clippy' and `rust-buffer-project' with testing paraphernalia.
Diffstat (limited to 'rust-mode-tests.el')
| -rw-r--r-- | rust-mode-tests.el | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/rust-mode-tests.el b/rust-mode-tests.el index 6d58906..42792ac 100644 --- a/rust-mode-tests.el +++ b/rust-mode-tests.el @@ -2650,6 +2650,15 @@ extern \"rust-intrinsic\" fn five() { "four" "five")))) +(ert-deftest rust-test-project-located () + (lexical-let* ((this-dir default-directory) + (test-dir (expand-file-name "test-project" this-dir)) + (manifest-file (expand-file-name "Cargo.toml" test-dir))) + (find-file (expand-file-name "test-project/foo.rs")) + (unwind-protect + (should (equal (expand-file-name (rust-buffer-project)) manifest-file)) + (kill-buffer)))) + ;; If electric-pair-mode is available, load it and run the tests that use it. If not, ;; no error--the tests will be skipped. (require 'elec-pair nil t) |
