Commit Graph

2044 Commits

Author SHA1 Message Date
Jeremie Juste 9014577df2 test-ob-R.el: add tests for how NA values are printed
* testing/lisp/test-ob-R.el (ert-deftest test-ob-r/NA-blank): new test
for :results value. Make sure that NA values in R data.frames are
empty string instead of nil previously

see https://orgmode.org/list/87pn1dufm2.fsf@gmail.com/
2021-05-03 00:29:09 +02:00
Jeremie Juste c0338142b7 test-ob-R.el: add tests for output with substrings matching prompt
* testing/lisp/test-ob-R.el (test-ob-r/output-with-<>): new test for output
  angle brackets
 (test-ob-R/output-nonprinted): New test for output results that aren't
explicitly printed.  (Here all the lines are expected to be printed
not just the last one)

Patch suggested by Jack Kamm:
https://orgmode.org/list/87h7slgbi5.fsf@gmail.com/
2021-05-03 00:18:33 +02:00
Bastien 379e22bfcc Merge branch 'maint' 2021-05-02 11:06:46 +02:00
Ihor Radchenko 0e7153e63d org-test: Fix wrong-numbre-of-arguments error on master+native-comp
* testing/org-test.el (org-test-at-time): Use correct number of
arguments in 'decode-time cl-letf binding. `decode-time' accepts up to
3 arguments on master.

The wrong-numbre-of-arguments error is raised on Emacs master
configured with native-comp support when running make test on Org mode
master.  Native-comp modifies function calls with optional arguments
in the way that omitted arguments are still provided as `nil'.  For
example, `decode-time' called as (decode-time time) in lisp source may
be compiled into (decode-time time nil nil) call by native-compiler.
If redefined `decode-time' does not accept 3 arguments, it result in
error.

See Emacs bug#48133.
2021-05-02 11:06:32 +02:00
Sébastien Miquel a2cb9b853d ob-tangle.el: Improve tangling
* lisp/ob-tangle.el (org-babel-tangle-collect-blocks): Group
collected blocks by tangled file name.
(org-babel-tangle): Avoid quadratic behavior in number of blocks and
set modes before writing to file.
* testing/lisp/test-ob-tangle.el (ob-tangle/block-order): Update test.
2021-05-01 22:30:42 +02:00
Bastien Guerry 047fa8c319 Merge branch 'maint' 2021-04-28 09:23:29 +02:00
Maxim Nikulin 3dbeb677e0 test-org-protocol.el: Add expected failures for file:/// URLs
* testing/lisp/test-org-protocol.el
(test-org-protocol/org-protocol-store-link-file,
test-org-protocol/org-protocol-capture-file): Add tests to document
that existing calls to `org-protocol-sanitize-uri' could make passed
URLs invalid by changing number of slashes after scheme.

Till a fix of the problem the new tests are marked as expected failures.

Unless a relatively recent commit 5748615c48, I would believe that
`org-protocol-sanitize-uri' was added by mistake to the initial
implementation.  Capture URLs are anyway escaped with percent encoding.
2021-04-28 09:21:06 +02:00
Maxim Nikulin 5e8f039aaa test-org-protocol.el: Fix the case for parse parameters with complex argument
* testing/lisp/test-org-protocol.el
(test-org-protocol/org-protocol-parse-parameters): Specify that the case
simulating real life capture uses new style parameters string
to prevent test failure.

It looks like a typo survived since addition of this case in 2216f4d2c7.
2021-04-28 09:11:05 +02:00
Cheong Yiu Fung a1184f7d61 Add `ancestors-full' visibility setup to `org-show-context-detail'
* lisp/org.el(org-show-context-detail): Add `ancestors-full' visibility setup.
(org-show-set-visibility): Update accordingly.
* testing/lisp/test-org.el: Add tests.
2021-04-27 22:26:29 +02:00
Bastien Guerry 31d48755bf Merge branch 'maint' 2021-04-27 09:43:11 +02:00
Bastien Guerry 13a1a4fb96 Be more consistent about treating tags as case-sensitive
* lisp/org-agenda.el (org-agenda-finalize):
(org-agenda-format-item): Do not downcase tags.
(org-downcase-keep-props): Remove unused function.
(org-agenda-filter-expand-tags): Do not case-fold search.

* lisp/org.el (org-tags-expand): Document `downcased' argument as
obsolete and do not allow to expand downcased tags.

* testing/lisp/test-org.el (test-org/tags-expand): Remove test for
downcased tags expansion.

* doc/org-manual.org (TODO keywords, tags, properties, etc.):
Suggest that user-defined are usually lowercase, but don't make it
a requirement.

Reported-by: David Masterson <dsmasterson92630@outlook.com>
Link: https://orgmode.org/list/SJ0PR03MB5455D8D0C4F71AA495A9ABF79B709@SJ0PR03MB5455.namprd03.prod.outlook.com/
2021-04-27 09:41:26 +02:00
Nicolas Goaziou 9402aaebe7 Merge branch 'maint' 2021-04-19 18:19:29 +02:00
Nicolas Goaziou bc3ed23d16 element: Interpret :post-blank property in strings
* lisp/org-element.el (org-element-interpret-data):
Interpret :post-blank property in strings.
* testing/lisp/test-org-element.el (test-org-element/interpret-data):
Add test.
2021-04-19 18:17:55 +02:00
Nicolas Goaziou 628bb4f324 lint: Improve checks for internal macros
* lisp/org-lint.el (org-lint-invalid-macro-argument-and-template): Add
arity checks for internal macros.
* testing/lisp/test-org-lint.el (test-org-lint/invalid-macro-argument-and-template):
Add tests.
2021-04-19 02:06:01 +02:00
Nicolas Goaziou 4941444f45 Merge branch 'maint' 2021-04-13 09:56:16 +02:00
Nicolas Goaziou bcc1b0f1bb ob-exp: Do not comma-escape inline source code
* lisp/ob-exp.el (org-babel-exp-code): Do not comma-escape inline
source code.
* testing/lisp/test-ob-exp.el (ob-exp/exports-inline-code): Add test.
2021-04-13 09:55:29 +02:00
Nicolas Goaziou 5d5d102254 Revert "element: Un-escape code in inline source blocks"
This reverts commit 4056e11ddc.

We shouldn't code escape inline source blocks, as escaping can be
inlined any time, at which point escape character is no longer treated
specially. E.g.,

    src_c{a
    ,* 2}

may become

    src_c{a ,* a}

where the comma is no longer an escape character.
2021-04-13 09:47:09 +02:00
Nicolas Goaziou b049f839b0 Merge branch 'maint' 2021-04-12 23:33:12 +02:00
Nicolas Goaziou 4056e11ddc element: Un-escape code in inline source blocks
* lisp/org-element.el (org-element-inline-src-block-parser): Un-escape
code in inline source blocks.
(org-element-inline-src-block-interpreter): Escape it again if
necessary.
* testing/lisp/test-org-element.el (test-org-element/inline-src-block-parser):
Add test.
2021-04-12 23:29:38 +02:00
Nicolas Goaziou 85a25e3169 Merge branch 'maint' 2021-04-10 12:08:33 +02:00
Nicolas Goaziou 19947a6e41 ox: Handle missing option value better
* lisp/ox.el (org-export--parse-option-keyword): Do not stop parsing
OPTIONS keyword when an option without a value is encountered.
* testing/lisp/test-ox.el (test-org-export/parse-option-keyword): Add
tset.

This is a followup to 7116914427.
2021-04-10 12:06:47 +02:00
Nicolas Goaziou f63bb5eea8 Merge branch 'maint' 2021-04-09 22:49:54 +02:00
Nicolas Goaziou 7116914427 ox: Do not choke on incomplete OPTIONS items
* lisp/ox.el (org-export--parse-option-keyword): Prevent "End of
file during parsing" error when an OPTIONS item is incomplete.
* lisp/org-lint.el (org-lint-unknown-options-item): Check for
incomplete options items.
* testing/lisp/test-org-lint.el (test-org-lint/unknown-options-item):
Add test.
2021-04-09 22:47:57 +02:00
Stefan Kangas 8cc992f7b2 Prefer HTTPS to HTTP for links to gnu.org 2021-03-21 14:29:13 -04:00
Kyle Meyer c1fa5ea76f Merge branch 'maint' 2021-03-21 13:41:39 -04:00
Kyle Meyer 5450d64202 ob-export: Give more informative error on unknown call reference
* lisp/ob-exp.el (org-babel-exp-process-buffer): Signal user-error
with an informative message rather than letting
org-babel-exp-do-export call fail due to an invalid INFO argument.
* testing/lisp/test-ob-exp.el (ob-exp/unknown-call-reference): Add
test.

Reported-by: Greg Minshall <minshall@umich.edu>
Ref: https://orgmode.org/list/628738.1616259666@apollo2.minshall.org
2021-03-21 13:41:31 -04:00
Robin Campbell Joy b241c126b4 ob-sql.el: Add support for SAP HANA
* lisp/ob-sql.el (org-babel-execute:sql, org-babel-sql-dbstring-saphana):
Add basic support for SAP HANA to SQL blocks.
* testing/lisp/test-ob-sql.el: Basic tests for generated db connection
string.

This change adds basic support for SAP HANA to SQL blocks by
specifying saphana as :engine.

It also adds a new header arg `dbinstance' in order to specify the SAP
HANA instance to connect to.
2021-03-16 23:53:09 -04:00
Kyle Meyer 4de1e053d1 test-ob-sqlite.el: Don't load ob-sqlite
* testing/lisp/test-ob-sqlite.el (ob-sqlite): Don't explicitly load
ob-sqlite.

ob-LANG tests check whether the corresponding ob- feature is
available, signaling missing-test-dependency if it's not.  Which ob-
libraries are loaded/tested can then controlled by the Makefile
variable BTEST_OB_LANGUAGES.

test-ob-sqlite.el, however, requires ob-sqlite before its featurep
call, unconditionally loading ob-sqlite and breaking the above setup.
2021-03-16 23:53:09 -04:00
Kyle Meyer 06dc62790e Merge branch 'maint' 2021-03-14 22:07:25 -04:00
Kyle Meyer 7470ee93a6 test-org-clock: Avoid daylight saving time failure
* testing/lisp/test-org-clock.el (test-org-clock/clocktable/match):
Shift times away from the beginning of the day to avoid unexpected
time totals due to DST changes.

test-org-clock/clocktable/match fails today in the US because at 2:00
clocks jumped to 3:00, and the total time check uses the range
2:00-4:00.
2021-03-14 22:06:22 -04:00
Stefan Monnier 129c33dddf * lisp/org-agenda.el: Use lexical-binding
- Removed the global (defvar date) and (defvar entry) so as not to
  conflict with function arguments of that name.  Instead I added such
  `defvar`s in the body of each of the functions where it
  seemed needed.
- I added some FIXMEs for some issues I found along the way.
- Added an `org-dlet` macro, just like I had done for `calendar-dlet`,
  but I also use `defvar` "manually" at some places, when splitting an
  existing `let` into a mix of `let`s and `dlet`s seemed too much trouble.
- Removed uses of `org-let and `org-let2` not only because I consider
  them offensive to my sense of aesthetics but also because they're
  basically incompatible with lexical scoping.
  I replaced them with uses of `cl-progv` which are a bit more verbose.
  Maybe we should define some `org-progv` macro on top of `cl-progv` to
  make the code less verbose, but I didn't do that because I like the
  fact that the current code makes uses of `eval` a bit more obvious
  (since these behave differently with lexical scoping than with
  lexical binding, it seemed worthwhile).
- Removed the use of `eval` in `org-store-agenda-views` which was only
  placed there in order to use a macro before it's defined (it would
  have been simpler/cleaner to just move that functions *after* the
  macro, but with the new code the problem doesn't occur any more anyway).
- Replaced a few `(lambda...) with actual closures.

Detailed changes follow:

(date, entry): Don't declare as being globally dynbound.
(org-agenda-format-date-aligned): Remove unused var `weekyear`.
(org-agenda-mode): `run-mode-hooks` is always available nowadays.
(org-agenda-undo): Remove unused var `last-undo-buffer`.
(org-agenda): Rename arg to `keys` and then dyn-bind it as `org-keys`.
Remove unused vars `buf` and `key`.
(org-agenda): Use `pcase` and `cl-progv` instead of `org-let`.
(org-let, org-let2): Mark as obsolete.
(org-agenda-run-series): Use `cl-progv` instead of `org-let` and `org-let2`.
(org-agenda-run-series): New function.
(org--batch-agenda): New function extracted from `org-batch-agenda`.
(org-batch-agenda): Use it.
(org--batch-agenda-csv): New function extracted from `org-batch-agenda-csv`.
(org-batch-agenda-csv): Use it.
(org--batch-store-agenda-views): New function, extracted from
`org-batch-store-agenda-views`.
(org-store-agenda-views, org-batch-store-agenda-views): Use it.
(org--batch-store-agenda-views): Use `cl-progv` instead of
`org-eval-in-environment`.
(org-agenda-write): Use `cl-progv` instead of `org-let`.
Use `with-current-buffer`.
(org-agenda-filter-any): Use `cl-some` instead of `eval`.
(org-agenda-list): Remove unused var `e`.
(org-search-view): η-reduce.
(crm-separator): Declare var.
(org-agenda-skip-if): Remove unused var `beg`.
(org-agenda-list-stuck-projects): Use a closure rather than `(lambda..).
(diary-modify-entry-list-string-function, diary-file-name-prefix)
(diary-display-function): Declare vars.
(org-diary): Declare `date` and `entry` as dynbound.
(org-agenda-get-day-entries): Use `org-dlet`.
(org-agenda-get-timestamps, org-agenda-get-progress)
(org-agenda-get-deadlines, org-agenda-get-scheduled, org-agenda-get-blocks):
Declare `date` as dynbound.
(org-agenda-get-sexps, org-class): Declare `date` and `entry` as dynbound.
(org-agenda-format-item): Declare the vars mentioned in
`org-compile-prefix-format` as dyn-bound.
Also binding `extra`, suggested by Kyle Meyer <kyle@kyleam.com>.
(org-compile-prefix-format): Remove unused var `e`.
Use `member` rather than or+equal.
(org-set-sorting-strategy): Minor simplification.
(org-entries-lessp): Use `org-dlet`.
(org-agenda-redo): Declare var `org-agenda-tag-filter-while-redo`.
(org-agenda-redo): Use `cl-progv` rather than `org-let`.
(org-agenda-filter): Remove unused var `rpl-fn`.
Use `org-pushnew-to-end` to replace `add-to-list` on lexical var.
(org-agenda-filter-by-tag): Remove unused var `n`.
(org-agenda-filter-apply): Use `org-dlet`.
(org-agenda-compute-starting-span): Remove unused var `dg`.
(org-agenda-forward-block): Remove unused var `pos`.
(org-archive-from-agenda): Declare var.
(org-agenda-refile): Remove unused var `pos`.
(org-agenda-headline-snapshot-before-repeat): Declare var.
(org-agenda-todo): Remove redundant use of `bound-and-true-p`.
(org-agenda-add-note): Remove unused var `hdmarker` and unused `arg`.
(org-agenda-change-all-lines): Remove unused var `pl`.
(org-agenda-priority): Remove unused var `marker`.
(org-agenda-set-effort): Remove unused var `newhead`.
(org-agenda-schedule): Remove unused var `type`.
(org-agenda-clock-cancel): Remove unused `arg`.
(org-agenda-execute-calendar-command): Use `org-dlet`.
(org-agenda-bulk-action): Use closures instead of `(lambda ...).
(org-agenda-show-the-flagging-note): Remove unused vars `heading` and
`newhead`.
(org-agenda-remove-flag): Avoid `setq`.

* testing/org-test.el (org--compile-when): New macro.
(org-test-jump): Use it so compilation doesn't fail or generate broken
code when `jump` is not available.

* testing/lisp/test-org-src.el:
* testing/lisp/test-org-attach.el:
* testing/lisp/test-org-agenda.el:
* testing/lisp/test-ob-java.el: Pass explicit filename to `require`
so as not to rely on ".../testing" being in `load-path` during compilation.

* lisp/org-num.el: Require` org`.

* lisp/org-macs.el (org-eval-in-environment): Declare obsolete.
(org-dlet, org-pushnew-to-end): New macros.

* doc/Makefile (org.texi, orgguide.texi, %_letter.tex): Simplify quoting.

* contrib/lisp/ob-sclang.el: Don't crash compilation when `sclang`
is not available.

* contrib/lisp/ob-clojure-literate.el: Don't crash compilation when `cider`
is not available.

* contrib/lisp/ob-arduino.el: Don't crash compilation when `arduino-mode`
is not available.

* .gitignore: Add files generated during `make packages/org`.
2021-03-09 22:56:33 -05:00
Kevin J. Foley 63c5cacb01 test-org-agenda.el: Test bulk functions
* testing/lisp/test-org-agenda.el (org-test-agenda-with-agenda):
Create macro to setup agenda for tests.
(test-org-agenda/bulk): Test that bulk actions are applied to marked
items.
(test-org-agenda/bulk-custom): Test that custom bulk actions are
applied to marked items.
(test-org-agenda/bulk-custom-arg-func): Test that argument collection
function is properly called for custom bulk functions.
2021-02-27 17:30:50 -05:00
Kyle Meyer 15c7385458 org-clone-subtree-with-time-shift: Support hour time shift
* lisp/org.el (org-clone-subtree-with-time-shift): Support hour time
shift.
* testing/lisp/test-org.el (test-org/clone-with-time-shift): Add
tests.

Suggested-by: Felipe Barros <felipebarros@protonmail.com>
Link: https://orgmode.org/list/urqRSSSRsE8In5xtAPBR8AZalNGUCBkwwVV8ujNSN8_AOyh0reiE8XMrY6eviTBYUsV5fCF5GyJAtw7FB8xo-XBPPpYHOnP0zQuce4odhI8=@protonmail.com
2021-02-25 00:05:51 -05:00
Kyle Meyer d21d200bc0 Merge branch 'maint' 2021-02-21 01:19:08 -05:00
Kyle Meyer 3a522ad539 agenda: Restore org-agenda-goto-date's date argument
* lisp/org-agenda.el (org-agenda-goto-date): Restore DATE argument
(removed in 7.9.3e), replacing unused SPAN argument.
* testing/lisp/test-org-agenda.el (test-org-agenda/goto-date): Add
test.

Among other changes, 93fcfe4d3 (2012-08-30) switched
org-agenda-goto-date's DATE argument to SPAN, moving the org-read-date
call out of the interactive form.  The new argument is unused, and
it's not clear that this part of the change was needed for the fix.
It prevents lisp callers from specifying a date, so move the
org-read-date call back to the interactive form.

Reported-by: Alan Schmitt <alan.schmitt@polytechnique.org>
Ref: https://orgmode.org/list/87pn10t83u.fsf@m4x.org
2021-02-21 01:18:07 -05:00
Kyle Meyer 72e368a2e9 Merge branch 'maint' 2021-01-24 22:17:01 -05:00
Kyle Meyer b99beaad18 org-macs: Add basic tests for org-matcher-time
* testing/lisp/test-org-macs.el (test-org-matcher-time): Add tests.

This includes of a test for the missing hour modifier added in the
previous commit.
2021-01-24 22:16:45 -05:00
tbanelwebmin@free.fr 9e8215f4a5 ob-C.el: Fix missing C, C++ declaration
* lisp/ob-C.el (org-babel-C-utility-header-to-C): Add declaration of
  strcmp() for C and C++.

* testing/examples/ob-C-test.org (Simple tests): Remove a spurious \n
  new line.
2021-01-14 21:20:00 +01:00
Kyle Meyer edda21e931 Merge branch 'maint' 2021-01-14 00:16:57 -05:00
TRS-80 1806abdc39 org-footnote: Fix inserting new footnote mangling drawers
* org-footnote.el (org-footnote-create-definition): Replace
  `forward-line' with `org-end-of-meta-data' to skip over any
  properties and/or drawers that may be present on the
  `org-footnote-section' heading (default "Footnotes").

TINYCHANGE
2021-01-14 00:16:40 -05:00
Christian Garbs d02c0218ef testing/lisp/test-org-archive.el: Fix test
* testing/lisp/test-org-archive.el
(test-org-archive/datetree): Fix test for locales that don't use
English weekday names.
2021-01-14 00:15:34 -05:00
Kyle Meyer 291993888d Merge branch 'maint' 2021-01-01 15:02:10 -05:00
Kyle Meyer 99eafe3787 Update copyright year to 2021 2021-01-01 14:59:01 -05:00
Kyle Meyer 25777d6e2c Merge branch 'maint' 2020-12-10 23:23:56 -05:00
Ihor Radchenko a03f17e49f Fix org-in-archived-heading-p
* lisp/org.el (org-in-archived-heading-p): When called on a heading
with a tag containing org-archive-tag string as a substring, that
heading was incorrectly recognised as archived.  Changed matching
against the whole :tag1:tag2:...: string to matching against tag list
as returned by `org-get-tags'.
* testing/lisp/test-org.el (test-org/in-archived-heading-p): Add test
when one of the heading tags contains org-archive-tag as a substring.
2020-12-10 22:25:12 -05:00
Kyle Meyer 3e39f82cd4 Merge branch 'maint' 2020-12-08 23:50:56 -05:00
Kyle Meyer 2eb5f0741f org-fixup-indentation: Fix regression in logbook adjustment
* lisp/org.el (org-fixup-indentation): Don't call indent-line-to with
a negative value.
* testing/lisp/test-org.el (test-org/promote):
(test-org/demote): Add tests.

The handling added in 11ef7454a (org.el (org-fixup-indentation): Fix
logbook drawers indentation, 2020-09-07) calls indent-line-to with a
value equal to the sum of current indentation and the DIFF argument,
but this can lead to a type error because DIFF may be negative.

Note that, aside from the headline-data test cases, the added tests on
top of the parent of e3b79ad2b (Allow a new value for
`org-adapt-indentation', 2020-02-09), which added the initial logbook
special case to org-fixup-indentation.

Reported-by: Duianto <otnaiud@gmail.com>
Ref: https://orgmode.org/list/CAE-tX7i5ew3ED3YX6jjx57qNuRtV0AumWKuE0W83YUUReKE5-g@mail.gmail.com
Reported-by: stardiviner <numbchild@gmail.com>
Ref: https://orgmode.org/list/CAL1eYuKObYzY2MHSQ+W08mW3TZ+83H45teOq_rHq9qz7-FEgKw@mail.gmail.com
2020-12-08 23:48:16 -05:00
Daniele Nicolodi 15469774dd org-table: Add mode flag to enable Calc units simplification mode
* org-table.el (org-table-eval-formula): Add the `u` mode flag to
enable Calc's units simplification mode.

* test-org-table.el (test-org-table/mode-string-u): Add Unit test for
the new mode flag.

* org-manual.org: Document new mode flag.
2020-11-24 20:59:39 -05:00
Stefan Kangas 1a480e01a4 Remove redundant 'function's around lambda
* contrib/lisp/org-secretary.el (join):
* contrib/lisp/ox-taskjuggler.el (org-taskjuggler-project-plan):
* lisp/org-clock.el (org-resolve-clocks):
* lisp/org-element.el (org-element--interpret-affiliated-keywords):
* lisp/org-list.el (org-list-struct, org-list-get-item-number)
(org-list-separating-blank-lines-number)
(org-list-struct-fix-bul, org-list-struct-apply-struct):
* lisp/org.el (org-agenda-files, org-toggle-heading):
* lisp/ox-ascii.el (org-ascii-table-row):
* lisp/ox-beamer.el (org-beamer--format-section)
(org-beamer-template):
* lisp/ox-odt.el (org-odt--render-image/formula):
* testing/org-batch-test-init.el (load-path): Remove redundant
'function's around lambda.
2020-11-18 22:02:19 -05:00
Ian Martins 93087e0b3a lisp/ob-java.el: Make the default to write to the current directory
* lisp/ob-java.el(org-babel-default-header-args:java): Add :dir
default.
(org-babel-execute:java): Check for existence of :dir in params using
alist-get instead of assq because we want a nil cdr to be false.
* testing/lisp/test-ob-java.el
(ob-java/simple, ob-java/simple-with-bracket)
(ob-java/simple-with-quote, ob-java/simple-return-int)
(ob-java/simple-return-float, ob-java/simple-return-string)
(ob-java/simple-with-main, ob-java/simple-with-two-methods)
(ob-java/simple-with-no-main, ob-java/simple-with-main-args-array)
(ob-java/simple-with-main-whitespace, ob-java/simple-with-class)
(ob-java/simple-with-non-public-class)
(ob-java/simple-with-class-and-package)
(ob-java/simple-with-class-attr)
(ob-java/simple-with-class-attr-with-package, ob-java/one-arg)
(ob-java/args-quoted-string, ob-java/integer-var)
(ob-java/var-with-main, ob-java/var-with-class)
(ob-java/var-with-class-and-package)
(ob-java/var-with-class-and-hanging-curlies, ob-java/two-vars)
(ob-java/string-var, ob-java/multiline-string-var)
(ob-java/return-vector-using-list, ob-java/return-vector-using-array)
(ob-java/read-return-list, ob-java/read-list-return-array)
(ob-java/read-return-list-with-package)
(ob-java/output-list-with-spaces, ob-java/list-var, ob-java/vector-var)
(ob-java/matrix-var, ob-java/matrix-var-with-header)
(ob-java/output-table-with-header, ob-java/inhomogeneous_table)
(ob-java/import_library, ob-java/import_library_inline)
(ob-java/tangle): Set :dir to nil to prevent tests from writing files
outside of temporary directory.
(ob-java/tangle-with-package, ob-java/simple-dir):
(ob-java/simple-dir-with-package): Move :dir param to be consistent
with other tests.

Most languages write tempfiles to babel's temporary directory, but
ob-java originally had to write them to the current directory instead.
I suspect this is because java puts the source file in package
directories, and babel doesn't expect subdirectories in the babel
temporary directory.  This change brings back the original behavior.

Reported-by: Jarmo Hurri <jarmo.hurri@iki.fi>
Ref: https://orgmode.org/list/87mtzk9n30.fsf@iki.fi
2020-11-17 06:38:56 -05:00