Maven

Build Maven Standalone Tests

Maven projects are not only used for building standalone or web applications they are also used for providing robust test frameworks using Java.

Running a standalone test is difficult, because the problem is that Maven packages the JAR file with only the main classes or test classes separately without the full dependencies.

The following describes how to create a standalone JAR file with test and main classes as well as all the dependencies.

1. Create a new XML file, e.g. test-jar-with-dependencies.xml, in the project path, e.g. src/main/assembly

2. Edit the test-jar-with-dependencies.xml file and copy

Use Dropbox to Host a Maven Repository

There are many Maven repository hosts that offer a free service if the project is open source software (OSS) such as Sonatype Nexus and JFrog Bintray.

There are times where privacy is required, such as commercial or experimental code, however the price to host such projects is not viable.

This is a guide to setup Maven public hosting of dependencies from a Dropbox account.

WARNING: This will not make the Maven repository private, but it can only be accessed if the URL is known.

1. Download the Dropbox desktop client.

2. Create a new directory in the Public folder that