emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
blob bc68540af30b7c982682a393ab895d81a2b70def 1373 bytes (raw)
name: testing/examples/ob-octave-test.org 	 # note: path name is non-authoritative(*)

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
 
#+Title: a collection of examples for ob-octave tests
#+OPTIONS: ^:nil

* Simple tests
  :PROPERTIES:
  :ID:       54dcd61d-cf6c-4d7a-b9e5-854953c8a753
  :END:
Number output
#+begin_src octave :exports results :results silent
ans = 10
#+end_src

Array output
#+begin_src octave :exports results :results silent
ans = 1:4'
#+end_src

* Input tests
  :PROPERTIES:
  :ID:       cc2d82bb-2ac0-45be-a0c8-d1463b86a3ba
  :END:
Input an integer variable
#+begin_src octave :exports results :results silent :var s=42
ans = s
#+end_src

Input an array
#+begin_src octave :exports results :results silent :var s='(1.0 2.0 3.0)
ans = s
#+end_src

Input a matrix
#+begin_src octave :exports results :results silent :var s='((1 2) (3 4))
ans = s
#+end_src

Input a string
#+begin_src octave :exports results :results silent :var s="test"
ans = s(1:2)
#+end_src

Input elisp nil
#+begin_src octave :exports results :results silent :var s='nil
ans = s
#+end_src


* Graphical tests

Graphics file. This test is performed by =ob-octave/graphics-file= in =testing/lisp/test-ob-octave.el=.
#+begin_src octave :results file graphics :file sombrero.png
sombrero;
#+end_src

Graphics file in a session. This test is performed by =ob-octave/graphics-file-session= in =testing/lisp/test-ob-octave.el=.
#+begin_src octave :session :results graphics file :file sombrero.png
sombrero;
#+end_src

debug log:

solving c0f04b7b9 ...
found c0f04b7b9 in https://yhetil.org/orgmode/87zgd1b4rn.fsf_-_@t14.reltub.ca/
found 9839d637e in https://git.savannah.gnu.org/cgit/emacs/org-mode.git
preparing index
index prepared:
100644 9839d637e9aed81838bdd6856e6326b9ed706946	testing/examples/ob-octave-test.org

applying [1/1] https://yhetil.org/orgmode/87zgd1b4rn.fsf_-_@t14.reltub.ca/
diff --git a/testing/examples/ob-octave-test.org b/testing/examples/ob-octave-test.org\r
index 9839d637e..c0f04b7b9 100644\r

Checking patch testing/examples/ob-octave-test.org...
Applied patch testing/examples/ob-octave-test.org cleanly.

index at:
100644 bc68540af30b7c982682a393ab895d81a2b70def	testing/examples/ob-octave-test.org

(*) Git path names are given by the tree(s) the blob belongs to.
    Blobs themselves have no identifier aside from the hash of its contents.^

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).