Skip to content

Commit

Permalink
Add three new test cases for stacking font-lock
Browse files Browse the repository at this point in the history
Two of the three are still failing, but one has been fixed.

Thanks to Kévin Le Gouguec (GH-172).
  • Loading branch information
jrblevin committed Jun 13, 2017
1 parent da85589 commit af9cc49
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions tests/markdown-test.el
Original file line number Diff line number Diff line change
Expand Up @@ -2868,6 +2868,23 @@ takes precedence)."
(markdown-test-range-has-face 28 28 markdown-markup-face)
(should (equal '((20 . 8734)) (get-text-property 8 'composition))))))

(ert-deftest test-markdown-font-lock/snake-case-code-in-heading ()
"Test underscores in inline code in headings."
:expected-result :failed
(markdown-test-string "# Title with `snake_case_code`"
(should-not (markdown-range-property-any 21 24 'face '(markdown-italic-face)))))

(ert-deftest test-markdown-font-lock/stars-in-code-in-heading ()
"Test asterisks in inline code in headings."
(markdown-test-string "# Title with `char** foo, int* bar`"
(should-not (markdown-test-range-has-face 20 29 markdown-italic-face))))

(ert-deftest test-markdown-font-lock/stars-in-code-in-blockquote ()
"Test asterisks in inline code in blockquote."
:expected-result :failed
(markdown-test-string "> Quote with `**stars**`"
(should-not (markdown-test-range-has-face 17 21 markdown-bold-face))))

;;; Markdown Parsing Functions:

(ert-deftest test-markdown-parsing/extend-region-function ()
Expand Down

0 comments on commit af9cc49

Please sign in to comment.