You are looking for Java libraries to solve a particular demand, and you need to test them without polluting your current project. Still, you don’t want to configure a Java framework too.

Step 1: Create the simplest Maven project 1

mvn -B archetype:generate -DgroupId=com.mycompany.app -DartifactId=my-app -DarchetypeArtifactId=maven-archetype-quickstart -DarchetypeVersion=1.4
cd my-app

Step 2: Add the dependency you want to test drive

And program the needed code.

Step 3: Add the plugin to pom.xml file 2

<plugin>
    <artifactId>maven-assembly-plugin</artifactId>
    <configuration>
    <archive>
        <manifest>
        <mainClass>fully.qualified.MainClass</mainClass>
        </manifest>
    </archive>
    <descriptorRefs>
        <descriptorRef>jar-with-dependencies</descriptorRef>
    </descriptorRefs>
    </configuration>
</plugin>

Step 4: Compile

mvn clean compile assembly:single

Step 5: Run

java -cp target/my-app-1.0-SNAPSHOT-jar-with-dependencies.jar com.mycompany.app.App