Merge branch 'maint'
This commit is contained in:
commit
929b65533a
|
@ -3090,7 +3090,7 @@ Assume point is at the beginning of the link."
|
||||||
(setq path (match-string-no-properties 1))
|
(setq path (match-string-no-properties 1))
|
||||||
(setq contents-begin (match-beginning 1))
|
(setq contents-begin (match-beginning 1))
|
||||||
(setq contents-end (match-end 1)))
|
(setq contents-end (match-end 1)))
|
||||||
;; Type 2: Standard link, i.e. [[http://orgmode.org][homepage]]
|
;; Type 2: Standard link, i.e. [[https://orgmode.org][homepage]]
|
||||||
((looking-at org-bracket-link-regexp)
|
((looking-at org-bracket-link-regexp)
|
||||||
(setq format 'bracket)
|
(setq format 'bracket)
|
||||||
(setq contents-begin (match-beginning 3))
|
(setq contents-begin (match-beginning 3))
|
||||||
|
@ -3139,14 +3139,14 @@ Assume point is at the beginning of the link."
|
||||||
(t
|
(t
|
||||||
(setq type "fuzzy")
|
(setq type "fuzzy")
|
||||||
(setq path raw-link))))
|
(setq path raw-link))))
|
||||||
;; Type 3: Plain link, e.g., http://orgmode.org
|
;; Type 3: Plain link, e.g., https://orgmode.org
|
||||||
((looking-at org-plain-link-re)
|
((looking-at org-plain-link-re)
|
||||||
(setq format 'plain)
|
(setq format 'plain)
|
||||||
(setq raw-link (match-string-no-properties 0))
|
(setq raw-link (match-string-no-properties 0))
|
||||||
(setq type (match-string-no-properties 1))
|
(setq type (match-string-no-properties 1))
|
||||||
(setq link-end (match-end 0))
|
(setq link-end (match-end 0))
|
||||||
(setq path (match-string-no-properties 2)))
|
(setq path (match-string-no-properties 2)))
|
||||||
;; Type 4: Angular link, e.g., <http://orgmode.org>. Unlike to
|
;; Type 4: Angular link, e.g., <https://orgmode.org>. Unlike to
|
||||||
;; bracket links, follow RFC 3986 and remove any extra
|
;; bracket links, follow RFC 3986 and remove any extra
|
||||||
;; whitespace in URI.
|
;; whitespace in URI.
|
||||||
((looking-at org-angle-link-re)
|
((looking-at org-angle-link-re)
|
||||||
|
|
|
@ -184,10 +184,10 @@ Possible properties are:
|
||||||
Example:
|
Example:
|
||||||
|
|
||||||
(setq org-protocol-project-alist
|
(setq org-protocol-project-alist
|
||||||
\\='((\"http://orgmode.org/worg/\"
|
\\='((\"https://orgmode.org/worg/\"
|
||||||
:online-suffix \".php\"
|
:online-suffix \".php\"
|
||||||
:working-suffix \".org\"
|
:working-suffix \".org\"
|
||||||
:base-url \"http://orgmode.org/worg/\"
|
:base-url \"https://orgmode.org/worg/\"
|
||||||
:working-directory \"/home/user/org/Worg/\")
|
:working-directory \"/home/user/org/Worg/\")
|
||||||
(\"http://localhost/org-notes/\"
|
(\"http://localhost/org-notes/\"
|
||||||
:online-suffix \".html\"
|
:online-suffix \".html\"
|
||||||
|
@ -688,7 +688,7 @@ the cdr of an element in `org-publish-project-alist', reuse
|
||||||
(let ((working-dir (expand-file-name
|
(let ((working-dir (expand-file-name
|
||||||
(or (plist-get project-plist :base-directory)
|
(or (plist-get project-plist :base-directory)
|
||||||
default-directory)))
|
default-directory)))
|
||||||
(base-url "http://orgmode.org/worg/")
|
(base-url "https://orgmode.org/worg/")
|
||||||
(strip-suffix (or (plist-get project-plist :html-extension) ".html"))
|
(strip-suffix (or (plist-get project-plist :html-extension) ".html"))
|
||||||
(working-suffix (if (plist-get project-plist :base-extension)
|
(working-suffix (if (plist-get project-plist :base-extension)
|
||||||
(concat "." (plist-get project-plist :base-extension))
|
(concat "." (plist-get project-plist :base-extension))
|
||||||
|
|
|
@ -82,9 +82,9 @@
|
||||||
"Test commenting of links at left margin."
|
"Test commenting of links at left margin."
|
||||||
(should
|
(should
|
||||||
(string-match
|
(string-match
|
||||||
(regexp-quote "# [[http://orgmode.org][Org mode]]")
|
(regexp-quote "# [[https://orgmode.org][Org mode]]")
|
||||||
(org-test-with-temp-text-in-file
|
(org-test-with-temp-text-in-file
|
||||||
"[[http://orgmode.org][Org mode]]
|
"[[https://orgmode.org][Org mode]]
|
||||||
#+header: :comments org :tangle \"test-ob-tangle.sh\"
|
#+header: :comments org :tangle \"test-ob-tangle.sh\"
|
||||||
#+begin_src sh
|
#+begin_src sh
|
||||||
echo 1
|
echo 1
|
||||||
|
|
|
@ -640,20 +640,20 @@ CLOCK: [2016-12-27 Wed 13:09]--[2016-12-28 Wed 15:09] => 26:00"
|
||||||
|--------------+---------|
|
|--------------+---------|
|
||||||
| *Total time* | *26:00* |
|
| *Total time* | *26:00* |
|
||||||
|--------------+---------|
|
|--------------+---------|
|
||||||
| [[Foo %5B%5Bhttp://orgmode.org%5D%5BOrg mode%5D%5D][Foo Org mode]] | 26:00 |"
|
| [[Foo %5B%5Bhttps://orgmode.org%5D%5BOrg mode%5D%5D][Foo Org mode]] | 26:00 |"
|
||||||
(org-test-with-temp-text
|
(org-test-with-temp-text
|
||||||
"* Foo [[http://orgmode.org][Org mode]]
|
"* Foo [[https://orgmode.org][Org mode]]
|
||||||
CLOCK: [2016-12-27 Wed 13:09]--[2016-12-28 Wed 15:09] => 26:00"
|
CLOCK: [2016-12-27 Wed 13:09]--[2016-12-28 Wed 15:09] => 26:00"
|
||||||
(test-org-clock-clocktable-contents ":link t"))))
|
(test-org-clock-clocktable-contents ":link t"))))
|
||||||
(should
|
(should
|
||||||
(equal
|
(equal
|
||||||
"| Headline | Time |
|
"| Headline | Time |
|
||||||
|------------------------+---------|
|
|-------------------------+---------|
|
||||||
| *Total time* | *26:00* |
|
| *Total time* | *26:00* |
|
||||||
|------------------------+---------|
|
|-------------------------+---------|
|
||||||
| [[Foo %5B%5Bhttp://orgmode.org%5D%5D][Foo http://orgmode.org]] | 26:00 |"
|
| [[Foo %5B%5Bhttps://orgmode.org%5D%5D][Foo https://orgmode.org]] | 26:00 |"
|
||||||
(org-test-with-temp-text
|
(org-test-with-temp-text
|
||||||
"* Foo [[http://orgmode.org]]
|
"* Foo [[https://orgmode.org]]
|
||||||
CLOCK: [2016-12-27 Wed 13:09]--[2016-12-28 Wed 15:09] => 26:00"
|
CLOCK: [2016-12-27 Wed 13:09]--[2016-12-28 Wed 15:09] => 26:00"
|
||||||
(test-org-clock-clocktable-contents ":link t")))))
|
(test-org-clock-clocktable-contents ":link t")))))
|
||||||
|
|
||||||
|
|
|
@ -143,7 +143,7 @@
|
||||||
(should
|
(should
|
||||||
(equal
|
(equal
|
||||||
'("* [123]" . 7)
|
'("* [123]" . 7)
|
||||||
(org-test-with-temp-text "* [[http://orgmode.org][123]]"
|
(org-test-with-temp-text "* [[https://orgmode.org][123]]"
|
||||||
(let ((org-columns-default-format "%ITEM")) (org-columns))
|
(let ((org-columns-default-format "%ITEM")) (org-columns))
|
||||||
(cons (get-char-property (point) 'org-columns-value-modified)
|
(cons (get-char-property (point) 'org-columns-value-modified)
|
||||||
(aref org-columns-current-maxwidths 0)))))
|
(aref org-columns-current-maxwidths 0)))))
|
||||||
|
|
|
@ -1722,14 +1722,14 @@ e^{i\\pi}+1=0
|
||||||
(should
|
(should
|
||||||
(equal
|
(equal
|
||||||
'("Orgmode.org")
|
'("Orgmode.org")
|
||||||
(org-test-with-temp-text "[[http://orgmode.org][Orgmode.org]]"
|
(org-test-with-temp-text "[[https://orgmode.org][Orgmode.org]]"
|
||||||
(org-element-contents
|
(org-element-contents
|
||||||
(org-element-map (org-element-parse-buffer) 'link 'identity nil t)))))
|
(org-element-map (org-element-parse-buffer) 'link 'identity nil t)))))
|
||||||
;; ... without description.
|
;; ... without description.
|
||||||
(should
|
(should
|
||||||
(equal
|
(equal
|
||||||
"http"
|
"https"
|
||||||
(org-test-with-temp-text "[[http://orgmode.org]]"
|
(org-test-with-temp-text "[[https://orgmode.org]]"
|
||||||
(org-element-property
|
(org-element-property
|
||||||
:type
|
:type
|
||||||
(org-element-map (org-element-parse-buffer) 'link 'identity nil t)))))
|
(org-element-map (org-element-parse-buffer) 'link 'identity nil t)))))
|
||||||
|
@ -1738,7 +1738,7 @@ e^{i\\pi}+1=0
|
||||||
(equal
|
(equal
|
||||||
"//orgmode.org/worg"
|
"//orgmode.org/worg"
|
||||||
(org-test-with-temp-text "[[Org:worg]]"
|
(org-test-with-temp-text "[[Org:worg]]"
|
||||||
(let ((org-link-abbrev-alist '(("Org" . "http://orgmode.org/"))))
|
(let ((org-link-abbrev-alist '(("Org" . "https://orgmode.org/"))))
|
||||||
(org-element-property
|
(org-element-property
|
||||||
:path
|
:path
|
||||||
(org-element-map (org-element-parse-buffer) 'link 'identity nil t))))))
|
(org-element-map (org-element-parse-buffer) 'link 'identity nil t))))))
|
||||||
|
@ -1746,7 +1746,7 @@ e^{i\\pi}+1=0
|
||||||
(should
|
(should
|
||||||
(equal
|
(equal
|
||||||
"127.0.0.1"
|
"127.0.0.1"
|
||||||
(org-test-with-temp-text "[[http://orgmode.org]]"
|
(org-test-with-temp-text "[[https://orgmode.org]]"
|
||||||
(let ((org-link-translation-function
|
(let ((org-link-translation-function
|
||||||
(lambda (type _) (cons type "127.0.0.1"))))
|
(lambda (type _) (cons type "127.0.0.1"))))
|
||||||
(org-element-property
|
(org-element-property
|
||||||
|
@ -1819,30 +1819,30 @@ e^{i\\pi}+1=0
|
||||||
(org-element-property :path (org-element-context)))))
|
(org-element-property :path (org-element-context)))))
|
||||||
;; Plain link.
|
;; Plain link.
|
||||||
(should
|
(should
|
||||||
(org-test-with-temp-text "A link: http://orgmode.org"
|
(org-test-with-temp-text "A link: https://orgmode.org"
|
||||||
(org-element-map (org-element-parse-buffer) 'link 'identity)))
|
(org-element-map (org-element-parse-buffer) 'link 'identity)))
|
||||||
;; Angular link. Follow RFC 3986.
|
;; Angular link. Follow RFC 3986.
|
||||||
(should
|
(should
|
||||||
(eq 'link
|
(eq 'link
|
||||||
(org-test-with-temp-text "A link: <point><http://orgmode.org>"
|
(org-test-with-temp-text "A link: <point><https://orgmode.org>"
|
||||||
(org-element-type (org-element-context)))))
|
(org-element-type (org-element-context)))))
|
||||||
(should
|
(should
|
||||||
(equal "//orgmode.org"
|
(equal "//orgmode.org"
|
||||||
(org-test-with-temp-text "A link: <point><http://orgmode\n.org>"
|
(org-test-with-temp-text "A link: <point><https://orgmode\n.org>"
|
||||||
(org-element-property :path (org-element-context)))))
|
(org-element-property :path (org-element-context)))))
|
||||||
;; Link abbreviation.
|
;; Link abbreviation.
|
||||||
(should
|
(should
|
||||||
(equal "http"
|
(equal "https"
|
||||||
(org-test-with-temp-text
|
(org-test-with-temp-text
|
||||||
"#+LINK: orgmode http://www.orgmode.org/\n[[orgmode:#docs]]"
|
"#+LINK: orgmode https://www.orgmode.org/\n[[orgmode:#docs]]"
|
||||||
(progn (org-mode-restart)
|
(progn (org-mode-restart)
|
||||||
(goto-char (1- (point-max)))
|
(goto-char (1- (point-max)))
|
||||||
(org-element-property :type (org-element-context))))))
|
(org-element-property :type (org-element-context))))))
|
||||||
;; Link abbreviation in a secondary string.
|
;; Link abbreviation in a secondary string.
|
||||||
(should
|
(should
|
||||||
(equal "http"
|
(equal "https"
|
||||||
(org-test-with-temp-text
|
(org-test-with-temp-text
|
||||||
"#+LINK: orgmode http://www.orgmode.org/\n* H [[orgmode:#docs]]"
|
"#+LINK: orgmode https://www.orgmode.org/\n* H [[orgmode:#docs]]"
|
||||||
(progn (org-mode-restart)
|
(progn (org-mode-restart)
|
||||||
(org-element-map (org-element-parse-buffer) 'link
|
(org-element-map (org-element-parse-buffer) 'link
|
||||||
(lambda (link) (org-element-property :type link))
|
(lambda (link) (org-element-property :type link))
|
||||||
|
@ -3139,15 +3139,15 @@ DEADLINE: <2012-03-29 thu.> SCHEDULED: <2012-03-29 thu.> CLOSED: [2012-03-29 thu
|
||||||
(org-test-parse-and-interpret "a radio-target"))
|
(org-test-parse-and-interpret "a radio-target"))
|
||||||
"a radio-target\n"))
|
"a radio-target\n"))
|
||||||
;; Links without description.
|
;; Links without description.
|
||||||
(should (equal (org-test-parse-and-interpret "[[http://orgmode.org]]")
|
(should (equal (org-test-parse-and-interpret "[[https://orgmode.org]]")
|
||||||
"[[http://orgmode.org]]\n"))
|
"[[https://orgmode.org]]\n"))
|
||||||
;; Links with a description, even one containing a link.
|
;; Links with a description, even one containing a link.
|
||||||
(should (equal (org-test-parse-and-interpret
|
(should (equal (org-test-parse-and-interpret
|
||||||
"[[http://orgmode.org][Org mode]]")
|
"[[https://orgmode.org][Org mode]]")
|
||||||
"[[http://orgmode.org][Org mode]]\n"))
|
"[[https://orgmode.org][Org mode]]\n"))
|
||||||
(should (equal (org-test-parse-and-interpret
|
(should (equal (org-test-parse-and-interpret
|
||||||
"[[http://orgmode.org][http://orgmode.org]]")
|
"[[https://orgmode.org][https://orgmode.org]]")
|
||||||
"[[http://orgmode.org][http://orgmode.org]]\n"))
|
"[[https://orgmode.org][https://orgmode.org]]\n"))
|
||||||
;; File links.
|
;; File links.
|
||||||
(should
|
(should
|
||||||
(equal (org-test-parse-and-interpret "[[file+emacs:todo.org]]")
|
(equal (org-test-parse-and-interpret "[[file+emacs:todo.org]]")
|
||||||
|
@ -3162,11 +3162,11 @@ DEADLINE: <2012-03-29 thu.> SCHEDULED: <2012-03-29 thu.> CLOSED: [2012-03-29 thu
|
||||||
;; Code-ref links.
|
;; Code-ref links.
|
||||||
(should (equal (org-test-parse-and-interpret "[[(ref)]]") "[[(ref)]]\n"))
|
(should (equal (org-test-parse-and-interpret "[[(ref)]]") "[[(ref)]]\n"))
|
||||||
;; Plain links.
|
;; Plain links.
|
||||||
(should (equal (org-test-parse-and-interpret "http://orgmode.org")
|
(should (equal (org-test-parse-and-interpret "https://orgmode.org")
|
||||||
"http://orgmode.org\n"))
|
"https://orgmode.org\n"))
|
||||||
;; Angular links.
|
;; Angular links.
|
||||||
(should (equal (org-test-parse-and-interpret "<http://orgmode.org>")
|
(should (equal (org-test-parse-and-interpret "<https://orgmode.org>")
|
||||||
"<http://orgmode.org>\n"))
|
"<https://orgmode.org>\n"))
|
||||||
;; Pathological case: link with a %-sign in description.
|
;; Pathological case: link with a %-sign in description.
|
||||||
(should (equal (org-test-parse-and-interpret "[[file://path][%s]]")
|
(should (equal (org-test-parse-and-interpret "[[file://path][%s]]")
|
||||||
"[[file://path][%s]]\n")))
|
"[[file://path][%s]]\n")))
|
||||||
|
@ -3589,7 +3589,7 @@ Text
|
||||||
;; Special case: objects in inline footnotes.
|
;; Special case: objects in inline footnotes.
|
||||||
(should
|
(should
|
||||||
(eq 'link
|
(eq 'link
|
||||||
(org-test-with-temp-text "[fn::[[<point>http://orgmode.org]]]"
|
(org-test-with-temp-text "[fn::[[<point>https://orgmode.org]]]"
|
||||||
(org-element-type (org-element-context)))))
|
(org-element-type (org-element-context)))))
|
||||||
;; Special case: tags looking like a link.
|
;; Special case: tags looking like a link.
|
||||||
(should-not
|
(should-not
|
||||||
|
|
|
@ -37,8 +37,8 @@
|
||||||
(org-feed-format-entry nil "%(concat \"success\" \"!\")" nil)))
|
(org-feed-format-entry nil "%(concat \"success\" \"!\")" nil)))
|
||||||
;; %a placeholder.
|
;; %a placeholder.
|
||||||
(should
|
(should
|
||||||
(equal "[[http://orgmode.org]]\n"
|
(equal "[[https://orgmode.org]]\n"
|
||||||
(org-feed-format-entry '(:link "http://orgmode.org") "%a" nil)))
|
(org-feed-format-entry '(:link "https://orgmode.org") "%a" nil)))
|
||||||
;; %t and %T placeholders.
|
;; %t and %T placeholders.
|
||||||
(should
|
(should
|
||||||
(equal (format-time-string (org-time-stamp-format nil nil))
|
(equal (format-time-string (org-time-stamp-format nil nil))
|
||||||
|
|
|
@ -74,7 +74,7 @@
|
||||||
(let ((org-footnote-auto-label t)) (org-footnote-new))
|
(let ((org-footnote-auto-label t)) (org-footnote-new))
|
||||||
(buffer-string))))
|
(buffer-string))))
|
||||||
(should-error
|
(should-error
|
||||||
(org-test-with-temp-text " [[http://orgmode.org][Org mode<point>]]"
|
(org-test-with-temp-text " [[https://orgmode.org][Org mode<point>]]"
|
||||||
(org-footnote-new)))
|
(org-footnote-new)))
|
||||||
;; Allow new footnotes in blank lines after an element or white
|
;; Allow new footnotes in blank lines after an element or white
|
||||||
;; spaces after an object.
|
;; spaces after an object.
|
||||||
|
|
|
@ -1801,12 +1801,12 @@
|
||||||
(should
|
(should
|
||||||
(equal '("Org")
|
(equal '("Org")
|
||||||
(org-test-with-temp-text
|
(org-test-with-temp-text
|
||||||
"* [[http://orgmode.org][Org]]\n** S<point>"
|
"* [[https://orgmode.org][Org]]\n** S<point>"
|
||||||
(org-get-outline-path))))
|
(org-get-outline-path))))
|
||||||
(should
|
(should
|
||||||
(equal '("http://orgmode.org")
|
(equal '("https://orgmode.org")
|
||||||
(org-test-with-temp-text
|
(org-test-with-temp-text
|
||||||
"* [[http://orgmode.org]]\n** S<point>"
|
"* [[https://orgmode.org]]\n** S<point>"
|
||||||
(org-get-outline-path))))
|
(org-get-outline-path))))
|
||||||
;; When WITH-SELF is non-nil, include current heading.
|
;; When WITH-SELF is non-nil, include current heading.
|
||||||
(should
|
(should
|
||||||
|
@ -3201,12 +3201,12 @@ SCHEDULED: <2017-05-06 Sat>
|
||||||
(progn (org-beginning-of-line) (looking-at-p "Item"))))))
|
(progn (org-beginning-of-line) (looking-at-p "Item"))))))
|
||||||
;; Leave point before invisible characters at column 0.
|
;; Leave point before invisible characters at column 0.
|
||||||
(should
|
(should
|
||||||
(org-test-with-temp-text "[[http://orgmode.org]]<point>"
|
(org-test-with-temp-text "[[https://orgmode.org]]<point>"
|
||||||
(let ((org-special-ctrl-a/e nil))
|
(let ((org-special-ctrl-a/e nil))
|
||||||
(org-beginning-of-line)
|
(org-beginning-of-line)
|
||||||
(bolp))))
|
(bolp))))
|
||||||
(should
|
(should
|
||||||
(org-test-with-temp-text "[[http://orgmode.org]]<point>"
|
(org-test-with-temp-text "[[https://orgmode.org]]<point>"
|
||||||
(let ((org-special-ctrl-a/e t))
|
(let ((org-special-ctrl-a/e t))
|
||||||
(org-beginning-of-line)
|
(org-beginning-of-line)
|
||||||
(bolp))))
|
(bolp))))
|
||||||
|
@ -3347,7 +3347,7 @@ SCHEDULED: <2017-05-06 Sat>
|
||||||
(eobp))))
|
(eobp))))
|
||||||
;; Get past invisible characters at the end of line.
|
;; Get past invisible characters at the end of line.
|
||||||
(should
|
(should
|
||||||
(org-test-with-temp-text "[[http://orgmode.org]]"
|
(org-test-with-temp-text "[[https://orgmode.org]]"
|
||||||
(org-end-of-line)
|
(org-end-of-line)
|
||||||
(eolp))))
|
(eolp))))
|
||||||
|
|
||||||
|
|
|
@ -2843,19 +2843,19 @@ Para2"
|
||||||
"Test `org-export-insert-image-links' specifications."
|
"Test `org-export-insert-image-links' specifications."
|
||||||
(should-not
|
(should-not
|
||||||
(member "file"
|
(member "file"
|
||||||
(org-test-with-parsed-data "[[http://orgmode.org][file:image.png]]"
|
(org-test-with-parsed-data "[[https://orgmode.org][file:image.png]]"
|
||||||
(org-element-map tree 'link
|
(org-element-map tree 'link
|
||||||
(lambda (l) (org-element-property :type l))))))
|
(lambda (l) (org-element-property :type l))))))
|
||||||
(should
|
(should
|
||||||
(member "file"
|
(member "file"
|
||||||
(org-test-with-parsed-data "[[http://orgmode.org][file:image.png]]"
|
(org-test-with-parsed-data "[[https://orgmode.org][file:image.png]]"
|
||||||
(org-element-map (org-export-insert-image-links tree info) 'link
|
(org-element-map (org-export-insert-image-links tree info) 'link
|
||||||
(lambda (l) (org-element-property :type l))))))
|
(lambda (l) (org-element-property :type l))))))
|
||||||
;; Properly set `:parent' property when replace contents with image
|
;; Properly set `:parent' property when replace contents with image
|
||||||
;; link.
|
;; link.
|
||||||
(should
|
(should
|
||||||
(memq 'link
|
(memq 'link
|
||||||
(org-test-with-parsed-data "[[http://orgmode.org][file:image.png]]"
|
(org-test-with-parsed-data "[[https://orgmode.org][file:image.png]]"
|
||||||
(org-element-map (org-export-insert-image-links tree info) 'link
|
(org-element-map (org-export-insert-image-links tree info) 'link
|
||||||
(lambda (l)
|
(lambda (l)
|
||||||
(org-element-type (org-element-property :parent l)))))))
|
(org-element-type (org-element-property :parent l)))))))
|
||||||
|
@ -2863,12 +2863,12 @@ Para2"
|
||||||
;; images.
|
;; images.
|
||||||
(should-not
|
(should-not
|
||||||
(member "file"
|
(member "file"
|
||||||
(org-test-with-parsed-data "[[http://orgmode.org][file:image.xxx]]"
|
(org-test-with-parsed-data "[[https://orgmode.org][file:image.xxx]]"
|
||||||
(org-element-map (org-export-insert-image-links tree info) 'link
|
(org-element-map (org-export-insert-image-links tree info) 'link
|
||||||
(lambda (l) (org-element-property :type l))))))
|
(lambda (l) (org-element-property :type l))))))
|
||||||
(should
|
(should
|
||||||
(member "file"
|
(member "file"
|
||||||
(org-test-with-parsed-data "[[http://orgmode.org][file:image.xxx]]"
|
(org-test-with-parsed-data "[[https://orgmode.org][file:image.xxx]]"
|
||||||
(org-element-map
|
(org-element-map
|
||||||
(org-export-insert-image-links tree info '(("file" . "xxx")))
|
(org-export-insert-image-links tree info '(("file" . "xxx")))
|
||||||
'link
|
'link
|
||||||
|
@ -4427,7 +4427,7 @@ Another text. (ref:text)
|
||||||
;; Replace plain links with contents, or with path.
|
;; Replace plain links with contents, or with path.
|
||||||
(should
|
(should
|
||||||
(equal "H Org mode\n"
|
(equal "H Org mode\n"
|
||||||
(org-test-with-temp-text "* H [[http://orgmode.org][Org mode]]"
|
(org-test-with-temp-text "* H [[https://orgmode.org][Org mode]]"
|
||||||
(let (org-export-registered-backends)
|
(let (org-export-registered-backends)
|
||||||
(org-export-define-backend 'test
|
(org-export-define-backend 'test
|
||||||
'((headline . (lambda (h _c i) (org-export-data-with-backend
|
'((headline . (lambda (h _c i) (org-export-data-with-backend
|
||||||
|
@ -4436,8 +4436,8 @@ Another text. (ref:text)
|
||||||
i)))))
|
i)))))
|
||||||
(org-export-as 'test)))))
|
(org-export-as 'test)))))
|
||||||
(should
|
(should
|
||||||
(equal "H http://orgmode.org\n"
|
(equal "H https://orgmode.org\n"
|
||||||
(org-test-with-temp-text "* H [[http://orgmode.org]]"
|
(org-test-with-temp-text "* H [[https://orgmode.org]]"
|
||||||
(let (org-export-registered-backends)
|
(let (org-export-registered-backends)
|
||||||
(org-export-define-backend 'test
|
(org-export-define-backend 'test
|
||||||
'((headline . (lambda (h _c i) (org-export-data-with-backend
|
'((headline . (lambda (h _c i) (org-export-data-with-backend
|
||||||
|
|
Loading…
Reference in New Issue