Skip to content

Commit 789314c

Browse files
committed
Skip markdown-export tests if export command is not installed
1 parent 182640f commit 789314c

2 files changed

Lines changed: 10 additions & 0 deletions

File tree

CHANGES.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111

1212
* Improvements:
1313
- `markdown-preview` displays the buffer name as the page title
14+
- skip export tests if export command is not installed
1415

1516
[gh-937]: https://github.com/jrblevin/markdown-mode/pull/937
1617

tests/markdown-test.el

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6296,6 +6296,7 @@ bar baz"
62966296

62976297
(ert-deftest test-markdown-export/kill-buffer-nil ()
62986298
"Test `markdown-export-kill-buffer' equal to nil."
6299+
(skip-unless (executable-find markdown-command))
62996300
(markdown-test-temp-file "inline.text"
63006301
(let* ((markdown-export-kill-buffer nil)
63016302
(markdown-command #'markdown-command-identity)
@@ -6306,6 +6307,7 @@ bar baz"
63066307

63076308
(ert-deftest test-markdown-export/kill-buffer-t ()
63086309
"Test `markdown-export-kill-buffer' equal to t."
6310+
(skip-unless (executable-find markdown-command))
63096311
(markdown-test-temp-file "inline.text"
63106312
(let* ((markdown-export-kill-buffer t)
63116313
(markdown-command #'markdown-command-identity)
@@ -6316,6 +6318,7 @@ bar baz"
63166318

63176319
(ert-deftest test-markdown-export/body-preamble ()
63186320
"Test `markdown-xhtml-body-preamble'."
6321+
(skip-unless (executable-find markdown-command))
63196322
(markdown-test-temp-file "inline.text"
63206323
(let* ((str "<!-- body preamble test -->")
63216324
(markdown-xhtml-body-preamble str)
@@ -6331,6 +6334,7 @@ bar baz"
63316334

63326335
(ert-deftest test-markdown-export/body-epilogue ()
63336336
"Test `markdown-xhtml-body-epilogue'."
6337+
(skip-unless (executable-find markdown-command))
63346338
(markdown-test-temp-file "inline.text"
63356339
(let* ((str "<!-- body epilogue test -->")
63366340
(markdown-xhtml-body-epilogue str)
@@ -6346,6 +6350,7 @@ bar baz"
63466350

63476351
(ert-deftest test-markdown-export/url-css-path ()
63486352
"Test `markdown-css-paths' as URL."
6353+
(skip-unless (executable-find markdown-command))
63496354
(let ((markdown-css-paths '("http://www.example.com/style.css")))
63506355
(markdown-test-temp-file "inline.text"
63516356
(let* ((markdown-export-kill-buffer nil)
@@ -6359,6 +6364,7 @@ bar baz"
63596364

63606365
(ert-deftest test-markdown-export/buffer-local-css-path ()
63616366
"Test buffer local `markdown-css-paths'"
6367+
(skip-unless (executable-find markdown-command))
63626368
(let ((markdown-css-paths '("/global.css")))
63636369
(markdown-test-temp-file "inline.text"
63646370
(setq-local markdown-css-paths '("/local.css"))
@@ -6373,6 +6379,7 @@ bar baz"
63736379

63746380
(ert-deftest test-markdown-export/relative-css-path ()
63756381
"Test relative `markdown-css-paths'."
6382+
(skip-unless (executable-find markdown-command))
63766383
(let ((markdown-css-paths '("./style.css")))
63776384
(markdown-test-temp-file "inline.text"
63786385
(let* ((markdown-export-kill-buffer nil)
@@ -6389,6 +6396,7 @@ bar baz"
63896396

63906397
(ert-deftest test-markdown-hook/before-export ()
63916398
"Test hook run before export XHTML."
6399+
(skip-unless (executable-find markdown-command))
63926400
(markdown-test-temp-file "lists.text"
63936401
(let* ((before-hook-run nil)
63946402
(orig-point (point))
@@ -6424,6 +6432,7 @@ bar baz"
64246432

64256433
(ert-deftest test-markdown-hook/after-export ()
64266434
"Test hook run after export XHTML."
6435+
(skip-unless (executable-find markdown-command))
64276436
(markdown-test-temp-file "lists.text"
64286437
(let* ((after-hook-run nil)
64296438
(markdown-command #'markdown-command-identity)

0 commit comments

Comments
 (0)