diff options
author | Dmitry Gutov <dgutov@yandex.ru> | 2016-06-27 07:26:46 +0300 |
---|---|---|
committer | Dmitry Gutov <dgutov@yandex.ru> | 2016-06-27 07:31:52 +0300 |
commit | 15c307417f7bc13b27f06994dd931cb04873a26f (patch) | |
tree | 25f2ce5d9c47052728892d193e2b64e07bf7a3aa /test | |
parent | 7f02dedfcae6ba0e3a646c1367c908af9b3dbe1d (diff) |
Also handle escaping when string begins with a quote
* lisp/progmodes/ruby-mode.el (ruby-toggle-string-quotes):
Handle quoting of the first character in the string.
* test/lisp/progmodes/ruby-mode-tests.el
(ruby-toggle-string-quotes-quotes-correctly): Update.
Diffstat (limited to 'test')
-rw-r--r-- | test/lisp/progmodes/ruby-mode-tests.el | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/test/lisp/progmodes/ruby-mode-tests.el b/test/lisp/progmodes/ruby-mode-tests.el index 5dd34f8ee4..97f277bff4 100644 --- a/test/lisp/progmodes/ruby-mode-tests.el +++ b/test/lisp/progmodes/ruby-mode-tests.el @@ -718,8 +718,8 @@ VALUES-PLIST is a list with alternating index and value elements." (ert-deftest ruby-toggle-string-quotes-quotes-correctly () (let ((pairs - '(("puts 'foo\"\\''" . "puts \"foo\\\"'\"") - ("puts \"foo'\\\"\"" . "puts 'foo\\'\"'")))) + '(("puts '\"foo\"\\''" . "puts \"\\\"foo\\\"'\"") + ("puts \"'foo'\\\"\"" . "puts '\\'foo\\'\"'")))) (dolist (pair pairs) (ruby-with-temp-buffer (car pair) (beginning-of-line) |