aboutsummaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/lisp/progmodes/cc-mode-tests.el12
1 files changed, 10 insertions, 2 deletions
diff --git a/test/lisp/progmodes/cc-mode-tests.el b/test/lisp/progmodes/cc-mode-tests.el
index ad7a52b40d9..64d52a952b6 100644
--- a/test/lisp/progmodes/cc-mode-tests.el
+++ b/test/lisp/progmodes/cc-mode-tests.el
@@ -40,7 +40,7 @@
40 (insert content) 40 (insert content)
41 (setq mode nil) 41 (setq mode nil)
42 (c-or-c++-mode) 42 (c-or-c++-mode)
43 (unless(eq expected mode) 43 (unless (eq expected mode)
44 (ert-fail 44 (ert-fail
45 (format "expected %s but got %s when testing '%s'" 45 (format "expected %s but got %s when testing '%s'"
46 expected mode content))))) 46 expected mode content)))))
@@ -53,11 +53,18 @@
53 (funcall do-test (concat " * " content) 'c-mode)) 53 (funcall do-test (concat " * " content) 'c-mode))
54 '("using \t namespace \t std;" 54 '("using \t namespace \t std;"
55 "using \t std::string;" 55 "using \t std::string;"
56 "using Foo = Bar;"
56 "namespace \t {" 57 "namespace \t {"
57 "namespace \t foo \t {" 58 "namespace \t foo \t {"
58 "class \t Blah_42 \t {" 59 "namespace \t foo::bar \t {"
60 "inline namespace \t foo \t {"
61 "inline namespace \t foo::bar \t {"
59 "class \t Blah_42 \t \n" 62 "class \t Blah_42 \t \n"
63 "class \t Blah_42;"
64 "class \t Blah_42 \t final {"
65 "struct \t Blah_42 \t final {"
60 "class \t _42_Blah:public Foo {" 66 "class \t _42_Blah:public Foo {"
67 "struct \t _42_Blah:public Foo {"
61 "template \t < class T >" 68 "template \t < class T >"
62 "template< class T >" 69 "template< class T >"
63 "#include <string>" 70 "#include <string>"
@@ -67,6 +74,7 @@
67 (mapc (lambda (content) (funcall do-test content 'c-mode)) 74 (mapc (lambda (content) (funcall do-test content 'c-mode))
68 '("struct \t Blah_42 \t {" 75 '("struct \t Blah_42 \t {"
69 "struct template {" 76 "struct template {"
77 "struct Blah;"
70 "#include <string.h>"))))) 78 "#include <string.h>")))))
71 79
72(ert-deftest c-mode-macro-comment () 80(ert-deftest c-mode-macro-comment ()