title: Testng - Configuration Failures
body: <p>Getting a Configuration failures while running my script from command line at a point where my code calls function from another class.</p>
  
  <p>I am using Eclipse Neon 2, Selenium Webdriver and Testng.</p>
  
  <p>My script works fine when I execute it from eclipse.It also works fine when I remove those function calls and add the respective code in that same class while command line execution, but it fails with those function calls when I try to execute the script from command line or .bat file.</p>
  
  <p>Below my project structure looks like;</p>
  
  <p>I have 3 different classes in a package</p>
  
  <pre><code>Testing
    Survey
     selection (package)
       -Class Variable_cfg (this is to define different variables)
       -Class Reuse_fuctions (I am adding all re-useable functions like send_email into this)
       -Class Main_test (this is main test, I will have many like this in future)
  </code></pre>
  
  <hr>
  
  <pre><code>public class Variable_cfg()
  {
      public static void variables() {....}
  }
  
  public class Reuse_functions()
  {
        public static void sendMail() {...}
        public static String generateRandomChars() throws IOException {}
        public static void clickScreenshot(String filename, WebDriver driver) throws IOException {}
        public static void startDeleting() throws IOException {}
  }
  
  public class Main_test()
  {
      @Parameters({ "browser" })
      @BeforeTest
      public void openbrowser(String browser) throws IOException {}
  
      @DataProvider(name = "runtimeparams")
      @BeforeTest
      public Object[][] createData1() {}
  
      @Test(priority=1,groups={"Chrome","Firefox","IE"},dataProvider="runtimeparams")
      public void runtest(String env) throws IOException {
  
          //here I am calling functions from Reuse_Functions class like 
          selection.Reuse_functions.generateRandomChars()...}
  
      @AfterMethod
      public void exittest(ITestResult result){
          //here I am calling functions from Reuse_Functions class like 
          selection.Reuse_functions.sendMail()
      }
  </code></pre>
  
  <p>if you could help me finding out the solution. Thank you!</p>
  
  <p>Below is my NIA_Main.xml file</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
  &lt;!DOCTYPE suite SYSTEM "http://testng.org/testng-1.0.dtd"&gt;
  
  &lt;suite name="Suite" parallel="false" &gt;
  
    &lt;test name="Test01"&gt; 
      &lt;parameter name="browser" value="Chrome" /&gt;
      &lt;classes&gt;
          &lt;class name="selection.Main_test" /&gt;
      &lt;/classes&gt;
    &lt;/test&gt;
  &lt;/suite&gt; &lt;!-- Suite --&gt;
  </code></pre>
  
  <p>and my bat file looks like</p>
  
  <pre><code>set ProjectPath=C:\Users\*******\workspace\Testing
  set classpath=%ProjectPath%\bin;%ProjectPath%\Lib\*
  java org.testng.TestNG %ProjectPath%\NIA_Main.xml
  </code></pre>
  
  <p>I am trying to create a bat file because I want to give to other functional QAs to execute. Otherwise I am running it through command line where I do set projectath and classpath variables before executing it.</p>