Adding a unit test to verify the use of the `linenothreshold` option
provided by the `highlight` directive [1]. The included document to test
will introduce two sets of `code-block` and `literalinclude` directives
where the first entry generates contents using line numbers and the
second entry generates contents not using line numbers, respectfully.
[1]: https://github.com/sphinx-doc/sphinx/blob/v1.8.4/sphinx/transforms/post_transforms/code.py#L85
Signed-off-by: James Knight <james.d.knight@live.com>
As conf.py has now numfig = True, needed to modify accordingly test for
links in html output.
This topic branch fixes#2405, #2414, and also makes for latex(pdf)
functional hyperlinks to named references, but only for literal blocks
(code-block or literalinclude).
modified: tests/roots/test-directive-code/caption.rst
modified: tests/roots/test-directive-code/conf.py
new file: tests/roots/test-directive-code/namedblocks.rst
modified: tests/test_directive_code.py
* rename a few test modules to make the names more consistent
* do not copy/use Sphinx from build/ (unnecessary without 2to3)
* use a temporary dir for *all* test projects, the source tree
will stay pristine that way (default is tests/build)
* speed up tests by ~3x by splitting up test projects and avoiding
rebuilds