Skip to content

Commit

Permalink
Merge pull request #790 from kuranari/remove-redundant-test
Browse files Browse the repository at this point in the history
Remove a redundant test
  • Loading branch information
syohex committed Aug 8, 2023
2 parents 5e15541 + a2abc03 commit f8a91fe
Showing 1 changed file with 10 additions and 18 deletions.
28 changes: 10 additions & 18 deletions tests/markdown-test.el
Original file line number Diff line number Diff line change
Expand Up @@ -2057,18 +2057,6 @@ Should not cause an infinite loop."
(should (string-equal (buffer-string) "* foo\n* bar\n * baz\n\n"))
(should (eq (point) 22)))))

(ert-deftest test-markdown-indentation/indent-checkbox-list ()
"Test `markdown-indent-line' with a list item with checkbox."
(let ((markdown-indent-on-enter 'indent-and-new-item))
(markdown-test-string " * [x] item 1"
(end-of-line)
(call-interactively #'markdown-enter-key)
(should (string-equal (buffer-string) " * [x] item 1\n * [ ] "))
(should (eq (point) 24))
(call-interactively #'markdown-enter-key)
(should (string-equal (buffer-string) " * [x] item 1\n\n"))
(should (eq (point) 17)))))

(ert-deftest test-markdown-indentation/indent-pre ()
"Test `markdown-indent-line' with a pre block."
(markdown-test-string
Expand Down Expand Up @@ -2112,12 +2100,16 @@ See GH-245."
(should (= (current-indentation) 0))))

(ert-deftest test-markdown-indentation/continue-gfm-task-lists ()
(markdown-test-string " - [X] item"
(end-of-line)
(let ((markdown-indent-on-enter 'indent-and-new-item))
(call-interactively #'markdown-enter-key))
(should (string-equal (buffer-string) " - [X] item\n - [ ] "))
(should (= (point) 28))))
"Test `markdown-enter-key' with a gfm task list item."
(let ((markdown-indent-on-enter 'indent-and-new-item))
(markdown-test-string " - [X] item"
(end-of-line)
(call-interactively #'markdown-enter-key)
(should (string-equal (buffer-string) " - [X] item\n - [ ] "))
(should (= (point) 28))
(call-interactively #'markdown-enter-key)
(should (string-equal (buffer-string) " - [X] item\n\n"))
(should (= (point) 18)))))

;;; Markup hiding tests:

Expand Down

0 comments on commit f8a91fe

Please sign in to comment.