[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] master 9c9952c 12/40: Add test for indentation of single line mir
From: |
Noam Postavsky |
Subject: |
[elpa] master 9c9952c 12/40: Add test for indentation of single line mirrors |
Date: |
Wed, 26 Oct 2016 23:06:32 +0000 (UTC) |
branch: master
commit 9c9952c19a1ed4c28e303a9903f77d9b998876e3
Author: Noam Postavsky <address@hidden>
Commit: Noam Postavsky <address@hidden>
Add test for indentation of single line mirrors
* yasnippet-tests.el (indent-mirrors-on-update): New test.
---
yasnippet-tests.el | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/yasnippet-tests.el b/yasnippet-tests.el
index 219b2b3..1d56fb8 100644
--- a/yasnippet-tests.el
+++ b/yasnippet-tests.el
@@ -240,6 +240,16 @@ $1 ------------------------")
XXXXX ---------------- XXXXX ----
XXXXX ------------------------"))))
+(ert-deftest indent-mirrors-on-update ()
+ "Check that mirrors are always kept indented."
+ (with-temp-buffer
+ (ruby-mode)
+ (yas-minor-mode 1)
+ (yas-expand-snippet "def $1\n$1\nend")
+ (yas-mock-insert "xxx")
+ ;; Assuming 2 space indent.
+ (should (string= "def xxx\n xxx\nend" (buffer-string)))))
+
(ert-deftest snippet-with-multiline-mirrors-issue-665 ()
"In issue 665, a multi-line mirror is attempted."
- [elpa] master 351c1e3 10/40: Don't indent first line of mirrors, (continued)
- [elpa] master 351c1e3 10/40: Don't indent first line of mirrors, Noam Postavsky, 2016/10/26
- [elpa] master 655bda8 07/40: Merge: restore backquote evaluation behaviour, Noam Postavsky, 2016/10/26
- [elpa] master 8907fd1 14/40: Escape yas-selected-text for new snippet., Noam Postavsky, 2016/10/26
- [elpa] master a4fafc3 16/40: Add test for loading snippet with same uuid, Noam Postavsky, 2016/10/26
- [elpa] master 8ca8c7d 13/40: Merge: a different fix for #712., Noam Postavsky, 2016/10/26
- [elpa] master 85a43ad 35/40: Explain about backquote expressions in doc, Noam Postavsky, 2016/10/26
- [elpa] master 3129040 24/40: Load snippet after saving, Noam Postavsky, 2016/10/26
- [elpa] master 1532e66 33/40: Fix saving of new snippets, Noam Postavsky, 2016/10/26
- [elpa] master 0ee86a2 23/40: Simplify `yas-new-snippet' load&save logic, Noam Postavsky, 2016/10/26
- [elpa] master 00be21c 36/40: Change cl dep to cl-lib for tests too, Noam Postavsky, 2016/10/26
- [elpa] master 9c9952c 12/40: Add test for indentation of single line mirrors,
Noam Postavsky <=
- [elpa] master 4296a86 15/40: yasnippet.el (yas--quote-string): Remove., Noam Postavsky, 2016/10/26
- [elpa] master d4da806 17/40: Fix removal of snippets by uuid, Noam Postavsky, 2016/10/26
- [elpa] master 42b0c26 18/40: Don't warn about modifications to other buffers, Noam Postavsky, 2016/10/26
- [elpa] master eaaec30 38/40: Replace all occurances of `capitaomorte', Noam Postavsky, 2016/10/26
- [elpa] master ff6f31e 37/40: Replace yas--with-temp-redefs with cl-letf, Noam Postavsky, 2016/10/26
- [elpa] master 244cdfa 26/40: Merge: Simplify `yas-new-snippet' load&save logic, Noam Postavsky, 2016/10/26
- [elpa] master 9500b00 21/40: Fix field navigation in the backwards direction, Noam Postavsky, 2016/10/26
- [elpa] master 309fe15 31/40: * Rakefile: Handle unset `warnings' parameter, Noam Postavsky, 2016/10/26
- [elpa] master 9cf9208 32/40: Fix test-rebindings, Noam Postavsky, 2016/10/26
- [elpa] master 7e0a0de 28/40: Use new name of python-in-string/comment in docs, Noam Postavsky, 2016/10/26