Browse Source

Merge branch 'master' of orgmode.org:org-mode

Bastien Guerry 13 years ago
parent
commit
984318cea5
3 changed files with 9 additions and 2 deletions
  1. 1 1
      lisp/ob-ref.el
  2. 1 1
      lisp/ob.el
  3. 7 0
      testing/org-test.el

+ 1 - 1
lisp/ob-ref.el

@@ -148,7 +148,7 @@ the variable."
 	(widen)
 	(goto-char (point-min))
 	(if (let* ((rx (regexp-quote ref))
-		   (res-rx (concat org-babel-result-regexp rx "[ \t]*$"))
+		   (res-rx (concat org-babel-result-regexp rx "[ \t]*.*$"))
 		   (src-rx (concat org-babel-src-name-regexp
 				   rx "\\(\(.*\)\\)?" "[ \t]*$")))
 	      ;; goto ref in the current buffer

+ 1 - 1
lisp/ob.el

@@ -1387,7 +1387,7 @@ following the source block."
 			(match-end 0))))
 	   (name (if on-lob-line
 		     (nth 0 (org-babel-lob-get-info))
-		   (nth 4 (or info (org-babel-get-src-block-info)))))
+		   (nth 4 (or info (org-babel-get-src-block-info 'light)))))
 	   (head (unless on-lob-line (org-babel-where-is-src-block-head)))
 	   found beg end)
       (when head (goto-char head))

+ 7 - 0
testing/org-test.el

@@ -222,10 +222,17 @@ files."
 		(file-name-nondirectory (buffer-file-name)))
 	       "/")))
 
+(defun org-test-touch-all-examples ()
+  (dolist (file (directory-files
+		 org-test-example-dir 'full
+		 "^\\([^.]\\|\\.\\([^.]\\|\\..\\)\\).*\\.org$"))
+    (find-file file)))
+
 (defun org-test-run-all-tests ()
   "Run all defined tests matching \"\\(org\\|ob\\)\".
 Load all test files first."
   (interactive)
+  (org-test-touch-all-examples)
   (org-test-load)
   (ert "\\(org\\|ob\\)"))