testing/lisp/test-org: actually check that org-open-at-point did the right thing

* testing/lisp/test-org.el (test-org/open-at-point): The test should
  leave the cursor one line above "Org Mode Manual" in the "*info*"
  buffer.  Try to switch to that buffer and check that point is where
  it should be, then kill the buffer.
This commit is contained in:
Achim Gratz 2014-06-02 21:05:46 +02:00
parent 45f840a6f1
commit 8e72c8fcfa
1 changed files with 8 additions and 3 deletions

View File

@ -1017,12 +1017,17 @@ drops support for Emacs 24.1 and 24.2."
(ert-deftest test-org/open-at-point ()
"Test `org-open-at-point' with link being a heading property."
(org-test-with-temp-text
"* Headline
(should
(org-test-with-temp-text
"* Headline
:PROPERTIES:
:URL: <point>[[info:org#Top]]
:END:"
(org-open-at-point)))
(org-open-at-point)
(and (switch-to-buffer "*info*")
(prog1
(looking-at "\nOrg Mode Manual")
(kill-buffer))))))