Getting error on using TestNG
<p>When running a java selendroid code with testNG, getting an error message, "A Java Exception has occurred." with below exception - </p>

<pre><code>Exception in thread "main" java.lang.NoClassDefFoundError: org/testng/TestNGException
at java.lang.Class.getDeclaredMethods0(Native Method)
at java.lang.Class.privateGetDeclaredMethods(Class.java:2688)
at java.lang.Class.privateGetMethodRecursive(Class.java:3035)
at java.lang.Class.getMethod0(Class.java:3005)
at java.lang.Class.getMethod(Class.java:1771)
at sun.launcher.LauncherHelper.validateMainClass(LauncherHelper.java:544)
at sun.launcher.LauncherHelper.checkAndLoadMain(LauncherHelper.java:526)
Caused by: java.lang.ClassNotFoundException: org.testng.TestNGException
at java.net.URLClassLoader$1.run(URLClassLoader.java:372)
at java.net.URLClassLoader$1.run(URLClassLoader.java:361)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:360)
at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
... 7 more
</code></pre>

<p>Below is the selendroid java code - </p>

<pre><code>    package com.selendroid.demo;

import org.openqa.selenium.WebDriver;

import io.selendroid.SelendroidDriver;
import io.selendroid.common.SelendroidCapabilities;
import io.selendroid.common.device.DeviceTargetPlatform;
import io.selendroid.standalone.SelendroidConfiguration;
import io.selendroid.standalone.SelendroidLauncher;

public class Sele {

    private WebDriver driver;

    public void setUp() throws Exception {

        System.out.println("------------------------Started");

        SelendroidConfiguration config = new SelendroidConfiguration();

        // Add the selendroid-test-app to the standalone server
        config.addSupportedApp("Demo.apk");

        // start the standalone server
        SelendroidLauncher selendroidServer = new SelendroidLauncher(config);
        selendroidServer.launchSelendroid();

        // Create the selendroid capabilities
        SelendroidCapabilities capa = new SelendroidCapabilities(
                "io.selendroid.androiddriver:0.16.0");

        capa.setAut("com.example.demo:1.0");
        capa.setPlatformVersion(DeviceTargetPlatform.ANDROID15);
        // capa.setEmulator(false);
        // capa.setCapability(SelendroidCapabilities.EMULATOR, true);
        // capa.setSerial("emulator-5554");
        SelendroidDriver driver = new SelendroidDriver(capa);

        capa.wait(100);
        driver = new SelendroidDriver(capa);



    }

    }
</code></pre>

<p>Not familiar with testng and selendroid so please give the solution in detail.</p>