Hi list, I've just found a bug in `org-test-with-temp-text' and have fixed it. Please find attached my patch for the fix. Here's the description from git commit message: According to the docstring, if the string "" appears in TEXT then the string "" is removed and point is placed there. The problem was that after string "" was removed, the point was *not* placed at the position of the removed text, rather, it was placed one character before that position which is wrong. The reason is that Emacs buffer position is a number started from 1, instead of 0, in other words, the value of `(point-min)' is 1 not 0. The problem is addressed by adding 1 to the calculated position. I'm going to report another bug together with a reproducer written as an "org-test". But my test relies on my fix in `org-test-with-temp-text'. Therefor, I will appreciate it if this patch can be taken care of as soon as possible. Thank you, York