diff options
Diffstat (limited to 'test/lisp/progmodes/ruby-mode-tests.el')
-rw-r--r-- | test/lisp/progmodes/ruby-mode-tests.el | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/test/lisp/progmodes/ruby-mode-tests.el b/test/lisp/progmodes/ruby-mode-tests.el index 8a75c83d2c3..117385ea3e8 100644 --- a/test/lisp/progmodes/ruby-mode-tests.el +++ b/test/lisp/progmodes/ruby-mode-tests.el @@ -567,6 +567,22 @@ VALUES-PLIST is a list with alternating index and value elements." (search-backward "_") (should (string= (ruby-add-log-current-method) "C::D#foo")))) +(ert-deftest ruby-add-log-current-method-singleton-referencing-outer () + (ruby-with-temp-buffer (ruby-test-string + "module M + | module N + | module C + | class D + | def C.foo + | _ + | end + | end + | end + | end + |end") + (search-backward "_") + (should (string= (ruby-add-log-current-method) "M::N::C.foo")))) + (ert-deftest ruby-add-log-current-method-after-inner-class () (ruby-with-temp-buffer (ruby-test-string "module M |