]> code.delx.au - gnu-emacs/blobdiff - test/automated/ruby-mode-tests.el
* lisp/progmodes/ruby-mode.el (ruby-toggle-block): Don't stop at
[gnu-emacs] / test / automated / ruby-mode-tests.el
index d5d262590b6dcee7d9e522e7dbfb9ae2096b8a7a..e84f55be93df9c383729bfab4045d04374f772c1 100644 (file)
@@ -309,6 +309,12 @@ VALUES-PLIST is a list with alternating index and value elements."
     (ruby-toggle-block)
     (should (string= "foo do |b|\n  b + 1\nend" (buffer-string)))))
 
+(ert-deftest ruby-toggle-block-with-interpolation ()
+  (ruby-with-temp-buffer "foo do\n  \"#{bar}\"\nend"
+    (beginning-of-line)
+    (ruby-toggle-block)
+    (should (string= "foo { \"#{bar}\" }" (buffer-string)))))
+
 (ert-deftest ruby-recognize-symbols-starting-with-at-character ()
   (ruby-assert-face ":@abc" 3 font-lock-constant-face))