[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [O] [Bug] test-org-export/before-parsing-hook
From: |
Nicolas Goaziou |
Subject: |
Re: [O] [Bug] test-org-export/before-parsing-hook |
Date: |
Wed, 30 Jan 2013 20:44:58 +0100 |
Hello,
Achim Gratz <address@hidden> writes:
> Aside from the fact that Eric's last commit broke compilation of all of
> Org and I had to back it out, yes I can. Here's my config (in other
> words the new exporter is active, otherwise that test may not even be
> run):
>
> ========= Additional files from contrib/lisp
> org-man.el org-export.el org-e-icalendar.el org-e-latex.el org-e-groff.el
> org-e-man.el org-e-html.el org-e-texinfo.el org-e-publish.el org-e-beamer.el
> org-e-odt.el org-e-confluence.el org-e-ascii.el
> ========= Org version
> make: Org-mode version 7.9.3d (release_7.9.3d-913-gff2d37 =>
> /usr/local/share/emacs/site-lisp/org)
Could you try this test instead? I don't trust `org-map-entries'.
#+begin_src emacs-lisp
(ert-deftest test-org-export/before-parsing-hook ()
"Test `org-export-before-parsing-hook'."
(should
(equal "Body 1\nBody 2\n"
(org-test-with-backend test
(org-test-with-temp-text "* Headline 1\nBody 1\n* Headline 2\nBody
2"
(let ((org-export-before-parsing-hook
'((lambda (backend)
(goto-char (point-min))
(while (re-search-forward org-outline-regexp-bol nil t)
(delete-region
(point-at-bol) (progn (forward-line) (point))))))))
(org-export-as 'test)))))))
#+end_src
Regards,
--
Nicolas Goaziou