Document the makeJar() method

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
When writing temporary projects, use more appropriate artifactIds

When we write a temporary project, it makes more sense to use the class'
name as artifactId than a semi-random directory name of the temporary
directory we just created.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Write out pom.xml files when generating temporary projects

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Always write temporary projects for non-Maven sources

When compiling a .java file that is contained in, say, a Downloads/
directory, we definitely do not want to compile all of the .java files
available in the complete Downloads/** directory structure.

Now, we could special-case .java files containing the source for a class
in the default package, while still trying to discover .java files
recursively when the class is in a package and the directory structure
agrees with the package name.

But that would just violate the Law of the Least Surprise and confuse
people. So let's just make a temporary project in *every* case where we
do not find a pom.xml file in the expected location.

Incidentally, this makes sure that we always include pom.xml files in
the generated .jar files.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Add a unit test for makeJar()

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Bump parent version to force a new MiniMaven version

Required for the bug fix regarding .jar file generation with sources (to
be precise, MiniMaven version >= 2.1.1 is required).

While at it, get rid of the scijava-common:tests dependency: the classes
we need for testing are contained in the scijava-common artifact proper
now.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Keep unit tests' temporary directories around

Now that we use SciJava common's TestUtils, the temporary directories
are guaranteed to be in the target/ directory. So let's keep them
around for further inspection after tests ran.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Ensure that .jar files include the correct sources

Now that we use a MiniMaven version that includes sources correctly, we
might just as well ensure that it keeps doing so, even in future versions.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
'Java' is really the name of the language implemented by this engine

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Merge branch 'legacy-editor'

This topic branch fixes bugs identified while improving ImageJ2's script
editor with an eye to the legacy code. In particular, we need to be able
to run ImageJ 1.x plugins (with a LegacyJavaRunner contained in the
imagej-legacy project) so that Fiji can switch over to using ImageJ2's
script editor instead of its stale Script Editor (from where ImageJ2's
version was developed).

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>