From 89eb3b0ae7dcb7ae819efd448899103b0d4ee93e Mon Sep 17 00:00:00 2001 From: Chong Yidong Date: Sun, 2 Dec 2012 14:06:32 +0800 Subject: [PATCH] Fix for bad test in ruby-mode-tests.el. * automated/ruby-mode-tests.el (ruby-add-log-current-method-examples): Don't use loop macro, to allow automated testing to work. --- test/ChangeLog | 6 ++++++ test/automated/ruby-mode-tests.el | 22 ++++++++++++---------- 2 files changed, 18 insertions(+), 10 deletions(-) diff --git a/test/ChangeLog b/test/ChangeLog index b66c2925287..21f0f29b73b 100644 --- a/test/ChangeLog +++ b/test/ChangeLog @@ -1,3 +1,9 @@ +2012-12-02 Chong Yidong + + * automated/ruby-mode-tests.el + (ruby-add-log-current-method-examples): Don't use loop macro, to + allow automated testing to work. + 2012-11-20 Stefan Monnier * automated/advice-tests.el (advice-tests--data): Remove. diff --git a/test/automated/ruby-mode-tests.el b/test/automated/ruby-mode-tests.el index ad48413b030..620fe72fb69 100644 --- a/test/automated/ruby-mode-tests.el +++ b/test/automated/ruby-mode-tests.el @@ -296,21 +296,23 @@ VALUES-PLIST is a list with alternating index and value elements." (let ((pairs '(("foo" . "#foo") ("C.foo" . ".foo") ("self.foo" . ".foo")))) - (loop for (name . value) in pairs - do (with-temp-buffer - (insert (ruby-test-string - "module M + (dolist (pair pairs) + (let ((name (car pair)) + (value (cdr pair))) + (with-temp-buffer + (insert (ruby-test-string + "module M | class C | def %s | end | end |end" - name)) - (ruby-mode) - (search-backward "def") - (forward-line) - (should (string= (ruby-add-log-current-method) - (format "M::C%s" value))))))) + name)) + (ruby-mode) + (search-backward "def") + (forward-line) + (should (string= (ruby-add-log-current-method) + (format "M::C%s" value)))))))) (defvar ruby-block-test-example (ruby-test-string -- 2.39.5