From mboxrd@z Thu Jan 1 00:00:00 1970 From: Rasmus Subject: Re: [patch, ox] #+INCLUDE resolves links Date: Thu, 02 Oct 2014 19:47:45 +0200 Message-ID: <87h9zmz7lq.fsf@gmx.us> References: <87k34x6bjd.fsf@gmx.us> <87lhpdurfh.fsf@gmx.us> <87bnq984hd.fsf@nicolasgoaziou.fr> <87bnq5zzp7.fsf@gmx.us> <87oau4ems5.fsf@nicolasgoaziou.fr> <87d2af1qyv.fsf@gmx.us> <87tx3po7kj.fsf@nicolasgoaziou.fr> <87mw9hcsy9.fsf@gmx.us> <87zjdh89ll.fsf@nicolasgoaziou.fr> <871tqskce9.fsf@gmx.us> <87y4sz7e1w.fsf@nicolasgoaziou.fr> <87lhoz7a5k.fsf@gmx.us> <542CFECD.5000609@gmail.com> <87bnpux349.fsf@gmx.us> <87tx3m76rz.fsf@nicolasgoaziou.fr> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:54197) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XZkTz-0007Kz-Rm for emacs-orgmode@gnu.org; Thu, 02 Oct 2014 13:48:08 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XZkTv-0001P7-9q for emacs-orgmode@gnu.org; Thu, 02 Oct 2014 13:48:03 -0400 Received: from plane.gmane.org ([80.91.229.3]:57374) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XZkTv-0001Ot-2t for emacs-orgmode@gnu.org; Thu, 02 Oct 2014 13:47:59 -0400 Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1XZkTs-0007jL-2J for emacs-orgmode@gnu.org; Thu, 02 Oct 2014 19:47:56 +0200 Received: from 109.201.154.141 ([109.201.154.141]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Thu, 02 Oct 2014 19:47:56 +0200 Received: from rasmus by 109.201.154.141 with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Thu, 02 Oct 2014 19:47:56 +0200 List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Nicolas Goaziou writes: > Hello, > > Rasmus writes: > >> Shoot. Fixed in attached (tested with texi2pdf). > > Applied. Thank you for this patch. Please also apply this patch to make "make test" pass. —Rasmus -- Don't panic!!! --=-=-= Content-Type: text/x-diff Content-Disposition: inline; filename=0001-test-ox.el-Fix-test-error-from-986037a.patch >From 04d90414a848a55ff602cfbc0b5f300299830732 Mon Sep 17 00:00:00 2001 From: rasmus Date: Thu, 2 Oct 2014 19:41:31 +0200 Subject: [PATCH] test-ox.el: Fix test-error from 986037a. * test-ox.el (test-org-export/expand-include): Updated tests. --- testing/lisp/test-ox.el | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/testing/lisp/test-ox.el b/testing/lisp/test-ox.el index 915a5a6..2642f4a 100644 --- a/testing/lisp/test-ox.el +++ b/testing/lisp/test-ox.el @@ -804,18 +804,18 @@ text (org-test-with-temp-text "#+INCLUDE: dummy.org" (org-export-expand-include-keyword))) ;; Full insertion with recursive inclusion. - (org-test-with-temp-text - (format "#+INCLUDE: \"%s/examples/include.org\"" org-test-dir) - (org-export-expand-include-keyword) - (should (equal (buffer-string) - "Small Org file with an include keyword. - -#+BEGIN_SRC emacs-lisp :exports results\n(+ 2 1)\n#+END_SRC - -Success! - -* Heading -body\n"))) + (should + (equal + (with-temp-buffer + (insert-file + (expand-file-name "examples/include.org" org-test-dir)) + (replace-regexp-in-string + (regexp-quote "#+INCLUDE: \"include2.org\"") + "Success!" (buffer-string))) + (org-test-with-temp-text + (format "#+INCLUDE: \"%s/examples/include.org\"" org-test-dir) + (org-export-expand-include-keyword) + (buffer-string)))) ;; Localized insertion. (org-test-with-temp-text (format "#+INCLUDE: \"%s/examples/include.org\" :lines \"1-2\"" @@ -829,7 +829,7 @@ body\n"))) "* Top heading\n** Heading\nbody\n" (org-test-with-temp-text (format - "* Top heading\n#+INCLUDE: \"%s/examples/include.org\" :lines \"9-\"" + "* Top heading\n#+INCLUDE: \"%s/examples/include.org\" :lines \"9-11\"" org-test-dir) (org-export-expand-include-keyword) (buffer-string)))) @@ -838,7 +838,7 @@ body\n"))) "* Top heading\n* Heading\nbody\n" (org-test-with-temp-text (format - "* Top heading\n#+INCLUDE: \"%s/examples/include.org\" :lines \"9-\" :minlevel 1" + "* Top heading\n#+INCLUDE: \"%s/examples/include.org\" :lines \"9-11\" :minlevel 1" org-test-dir) (org-export-expand-include-keyword) (buffer-string)))) -- 2.1.2 --=-=-=--