Skip to content

Commit d8b482a

Browse files
committed
Add syntax highlight not supported by current php-mode
1 parent 52d8311 commit d8b482a

File tree

2 files changed

+8
-2
lines changed

2 files changed

+8
-2
lines changed

php-mode-test.el

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -721,7 +721,12 @@ style from Drupal."
721721
(search-forward "SpaceName")
722722
(goto-char (match-beginning 0))
723723
(should (eq 'php-constant
724-
(get-text-property (point) 'face)))))
724+
(get-text-property (point) 'face)))
725+
(search-forward-regexp "\\\\My_\\(Class\\)")
726+
(should (eq 'php-constant
727+
(get-text-property (match-beginning 0) 'face)))
728+
(should (eq 'php-constant
729+
(get-text-property (match-beginning 1) 'face)))))
725730

726731
(ert-deftest php-mode-test-variables()
727732
"Proper highlighting for variables."

tests/identifiers.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,4 +12,5 @@
1212
// When calling a method, the class name should be highlighted with
1313
// the constant face. Just like c++-mode "NS::Class::method()"
1414
ClassName::method();
15-
\SpaceName\ClassName::method();
15+
\SpaceName\ClassName::method();
16+
\My_Class::method();

0 commit comments

Comments
 (0)