|
|
@@ -423,7 +423,7 @@ example in the [[* emacs lisp source reference][emacs lisp source reference]].
|
|
|
|
|
|
|
|
|
|
|
|
-* Bugs [7/10]
|
|
|
+* Bugs [8/10]
|
|
|
|
|
|
** TODO ruby new variable creation
|
|
|
Ruby doesn't seem able to handle the creation of new variables
|
|
|
@@ -439,7 +439,33 @@ total/table.size
|
|
|
: -:4:in `main': undefined local variable or method `total' for main:Object (NameError)
|
|
|
: from -:7
|
|
|
|
|
|
-** TODO R code execution seems to choke on certain inputs
|
|
|
+** TODO cursor movement when evaluating source blocks
|
|
|
+ E.g. the pie chart example. Despite the save-window-excursion in
|
|
|
+ litorgy-execute:R. (I never learned how to do this properly: org-R
|
|
|
+ jumps all over the place...)
|
|
|
+
|
|
|
+** DONE R code execution seems to choke on certain inputs
|
|
|
+Currently the R code seems to work on vertical (but not landscape)
|
|
|
+tables
|
|
|
+
|
|
|
+#+srcname: little-fake
|
|
|
+#+begin_src emacs-lisp
|
|
|
+"schulte"
|
|
|
+#+end_src
|
|
|
+
|
|
|
+#+begin_src R :var num=little-fake
|
|
|
+num
|
|
|
+#+end_src
|
|
|
+
|
|
|
+#+resname:
|
|
|
+: schulte
|
|
|
+: 11
|
|
|
+: 11
|
|
|
+: 11
|
|
|
+: schulte
|
|
|
+: 9
|
|
|
+: 9
|
|
|
+: 11
|
|
|
|
|
|
#+srcname: set-debug-on-error
|
|
|
#+begin_src emacs-lisp :results silent
|
|
|
@@ -452,14 +478,22 @@ total/table.size
|
|
|
#+end_src
|
|
|
|
|
|
#+srcname: bug-R-number-evaluation
|
|
|
-#+begin_src R :var table=bug-numerical-table :results silent
|
|
|
-mean(table)
|
|
|
+#+begin_src R :var table=bug-numerical-table :results replace
|
|
|
+mean(mean(table))
|
|
|
#+end_src
|
|
|
|
|
|
-** TODO cursor movement when evaluating source blocks
|
|
|
- E.g. the pie chart example. Despite the save-window-excursion in
|
|
|
- litorgy-execute:R. (I never learned how to do this properly: org-R
|
|
|
- jumps all over the place...)
|
|
|
+#+resname:
|
|
|
+: 2
|
|
|
+
|
|
|
+#+tblname: bug-vert-table
|
|
|
+| 1 |
|
|
|
+| 2 |
|
|
|
+| 3 |
|
|
|
+
|
|
|
+#+srcname: bug-R-vertical-table
|
|
|
+#+begin_src R :var table=bug-vert-table :results silent
|
|
|
+mean(table)
|
|
|
+#+end_src
|
|
|
|
|
|
** DEFERRED org bug/request: prevent certain org behaviour within code blocks
|
|
|
E.g. [[]] gets recognised as a link (when there's text inside the
|
|
|
@@ -605,41 +639,41 @@ Evaluate all the cells in this table for a comprehensive test of the
|
|
|
litorgy functionality.
|
|
|
|
|
|
#+TBLNAME: litorgy-tests
|
|
|
-| functionality | block | arg | expected | results | pass |
|
|
|
-|-------------------------+-------------------------+-----+-------------+-------------+-------------------------------|
|
|
|
-| basic evaluation | | | | | pass |
|
|
|
-|-------------------------+-------------------------+-----+-------------+-------------+-------------------------------|
|
|
|
-| emacs lisp | basic-elisp | | 5 | 5 | pass |
|
|
|
-| shell | basic-shell | | 6 | 6 | pass |
|
|
|
-| ruby | basic-ruby | | litorgy | litorgy | pass |
|
|
|
-| python | basic-python | | hello world | hello world | pass |
|
|
|
-| R | basic-R | | 13 | 13 | pass |
|
|
|
-|-------------------------+-------------------------+-----+-------------+-------------+-------------------------------|
|
|
|
-| tables | | | | | pass |
|
|
|
-|-------------------------+-------------------------+-----+-------------+-------------+-------------------------------|
|
|
|
-| emacs lisp | table-elisp | | 3 | 3 | pass |
|
|
|
-| ruby | table-ruby | | 1-2-3 | 1-2-3 | pass |
|
|
|
-| python | table-python | | 5 | 5 | pass |
|
|
|
-| R | table-R | | 3.5 | 3.5 | pass |
|
|
|
-|-------------------------+-------------------------+-----+-------------+-------------+-------------------------------|
|
|
|
-| source block references | | | | | pass |
|
|
|
-|-------------------------+-------------------------+-----+-------------+-------------+-------------------------------|
|
|
|
-| all languages | chained-ref-last | | Array | Array | pass |
|
|
|
-|-------------------------+-------------------------+-----+-------------+-------------+-------------------------------|
|
|
|
-| source block functions | | | | | pass |
|
|
|
-|-------------------------+-------------------------+-----+-------------+-------------+-------------------------------|
|
|
|
-| emacs lisp | defun-fibb | | fibbd | fibbd | pass |
|
|
|
-| run over | Fibonacci | 0 | 1 | 1 | pass |
|
|
|
-| a | Fibonacci | 1 | 1 | 1 | pass |
|
|
|
-| variety | Fibonacci | 2 | 2 | 2 | pass |
|
|
|
-| of | Fibonacci | 3 | 3 | 3 | pass |
|
|
|
-| different | Fibonacci | 4 | 5 | 5 | pass |
|
|
|
-| arguments | Fibonacci | 5 | 8 | 8 | pass |
|
|
|
-|-------------------------+-------------------------+-----+-------------+-------------+-------------------------------|
|
|
|
-| bug fixing | | | | | pass |
|
|
|
-|-------------------------+-------------------------+-----+-------------+-------------+-------------------------------|
|
|
|
-| simple ruby arrays | ruby-array-test | | 3 | 3 | pass |
|
|
|
-| R number evaluation | bug-R-number-evaluation | | 2 | #ERROR | expected "2" but was "#ERROR" |
|
|
|
+| functionality | block | arg | expected | results | pass |
|
|
|
+|-------------------------+-------------------------+-----+-------------+-------------+------|
|
|
|
+| basic evaluation | | | | | pass |
|
|
|
+|-------------------------+-------------------------+-----+-------------+-------------+------|
|
|
|
+| emacs lisp | basic-elisp | | 5 | 5 | pass |
|
|
|
+| shell | basic-shell | | 6 | 6 | pass |
|
|
|
+| ruby | basic-ruby | | litorgy | litorgy | pass |
|
|
|
+| python | basic-python | | hello world | hello world | pass |
|
|
|
+| R | basic-R | | 13 | 13 | pass |
|
|
|
+|-------------------------+-------------------------+-----+-------------+-------------+------|
|
|
|
+| tables | | | | | pass |
|
|
|
+|-------------------------+-------------------------+-----+-------------+-------------+------|
|
|
|
+| emacs lisp | table-elisp | | 3 | 3 | pass |
|
|
|
+| ruby | table-ruby | | 1-2-3 | 1-2-3 | pass |
|
|
|
+| python | table-python | | 5 | 5 | pass |
|
|
|
+| R | table-R | | 3.5 | 3.5 | pass |
|
|
|
+|-------------------------+-------------------------+-----+-------------+-------------+------|
|
|
|
+| source block references | | | | | pass |
|
|
|
+|-------------------------+-------------------------+-----+-------------+-------------+------|
|
|
|
+| all languages | chained-ref-last | | Array | Array | pass |
|
|
|
+|-------------------------+-------------------------+-----+-------------+-------------+------|
|
|
|
+| source block functions | | | | | pass |
|
|
|
+|-------------------------+-------------------------+-----+-------------+-------------+------|
|
|
|
+| emacs lisp | defun-fibb | | fibbd | fibbd | pass |
|
|
|
+| run over | Fibonacci | 0 | 1 | 1 | pass |
|
|
|
+| a | Fibonacci | 1 | 1 | 1 | pass |
|
|
|
+| variety | Fibonacci | 2 | 2 | 2 | pass |
|
|
|
+| of | Fibonacci | 3 | 3 | 3 | pass |
|
|
|
+| different | Fibonacci | 4 | 5 | 5 | pass |
|
|
|
+| arguments | Fibonacci | 5 | 8 | 8 | pass |
|
|
|
+|-------------------------+-------------------------+-----+-------------+-------------+------|
|
|
|
+| bug fixing | | | | | pass |
|
|
|
+|-------------------------+-------------------------+-----+-------------+-------------+------|
|
|
|
+| simple ruby arrays | ruby-array-test | | 3 | 3 | pass |
|
|
|
+| R number evaluation | bug-R-number-evaluation | | 2 | 2 | pass |
|
|
|
#+TBLFM: $5='(if (= (length $3) 1) (progn (message (format "running %S" '(sbe $2 (n $3)))) (sbe $2 (n $3))) (sbe $2))::$6='(if (string= $4 $5) "pass" (format "expected %S but was %S" $4 $5))
|
|
|
|
|
|
** basic tests
|