From 23565783ca66e2aafc2aa03796e09dde4ae11c1a Mon Sep 17 00:00:00 2001 From: Stig Brautaset Date: Wed, 7 Jun 2017 23:01:56 +0100 Subject: Fix footnote test --- ox-jira.el | 6 +++--- test/ox-jira-test.el | 7 ++++--- 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/ox-jira.el b/ox-jira.el index 514eb49..0379456 100644 --- a/ox-jira.el +++ b/ox-jira.el @@ -212,8 +212,8 @@ information." CONTENTS is nil. INFO is a plist holding contextual information." (let* ((anchor (ox-jira--footnote-anchor footnote-reference)) - (ref (ox-jira--footnote-ref anchor))) - (format "{anchor:back%s}[^%s^|#%s]" + (ref (ox-jira--footnote-ref anchor))) + (format "{anchor:fnr%s}[^%s^|#fn%s]" anchor ref anchor))) (defun ox-jira-footnote-definition (footnote-definition contents info) @@ -222,7 +222,7 @@ CONTENTS is nil. INFO is a plist holding contextual information." (let* ((anchor (ox-jira--footnote-anchor footnote-definition)) (ref (ox-jira--footnote-ref anchor))) - (format "{anchor:%s}[^%s^|#back%s] %s" + (format "{anchor:fn%s}[^%s^|#fnr%s] %s" anchor ref anchor contents))) ;; Headlines are a little bit more complex. I'm not even attempting to support diff --git a/test/ox-jira-test.el b/test/ox-jira-test.el index 8ac4a7b..688ed4a 100644 --- a/test/ox-jira-test.el +++ b/test/ox-jira-test.el @@ -353,11 +353,12 @@ formatted (equal "----\n" (to-jira "-------\n")))) (ert-deftest ox-jira-test/footnotes () - (should (equal "fi fo{anchor:backfn1}[^1^|#fn1]. Another one{anchor:backfn2}[^2^|#fn2]. + (should (equal "fi fo{anchor:fnr1}[^1^|#fn1]. Another one{anchor:fnr2}[^2^|#fn2]. h1. Footnotes -{anchor:fn1}[^1^|#backfn1] fa fum. -{anchor:fn2}[^2^|#backfn2] fut fut. +{anchor:fn1}[^1^|#fnr1] fa fum. + +{anchor:fn2}[^2^|#fnr2] fut fut. " (to-jira "fi fo[fn:1]. Another one[fn:2]. * Footnotes -- cgit v1.2.3