title: How to pass input from command line to junit maven test program
body: <p>I wrote a junit test to add two numbers. I need to pass this numbers from command line. I am running this junit test from maven tool as</p>
  
  <pre><code>mvn -Dtest=AddNumbers
  </code></pre>
  
  <p>My test program looks like this</p>
  
  <pre><code>int num1 = 1;
  int num2 = 2;
  
  @Test
  public void addNos() {
    System.out.println((num1 + num2));
  }
  </code></pre>
  
  <p>How to pass these numbers from command line?</p>