title: I got Initialization error in Cucumber with maven and selenium
body: <p><strong>Test Runner</strong><br />
  import org.junit.runner.RunWith;</p>
  <pre><code>import cucumber.api.CucumberOptions;
  import cucumber.api.junit.Cucumber;
  
  @RunWith(Cucumber.class)
  @CucumberOptions(features=&quot;features&quot;,glue={&quot;stepDefinition&quot;})
  public class TestRunner {
  
  }
  </code></pre>
  <p><strong>MyApplication.feature</strong></p>
  <pre><code>Feature: Test test smoke scenario
  
    Scenario Outline: Test  login with valid credentials
      Given open fireFox and start application
      When I enter valid &quot;username&quot; and valid &quot;password&quot;
      Then User should be able to login successfully
  
  Examples: 
        | username   | password          |
        | 9739817000 | mnbvcxz  |
        | 9739817001 | mnbvcxz1  |
        | 9739817002 | mnbvcxz2  |
  </code></pre>
  <p><strong>Maven POM</strong></p>
  <pre><code>&lt;groupId&gt;demo&lt;/groupId&gt;
    &lt;artifactId&gt;prac&lt;/artifactId&gt;
    &lt;version&gt;0.0.1-SNAPSHOT&lt;/version&gt;
    &lt;packaging&gt;jar&lt;/packaging&gt;
  
    &lt;name&gt;prac&lt;/name&gt;
    &lt;url&gt;http://maven.apache.org&lt;/url&gt;
  
    &lt;properties&gt;
      &lt;project.build.sourceEncoding&gt;UTF-8&lt;/project.build.sourceEncoding&gt;
    &lt;/properties&gt;
  
    &lt;dependencies&gt;
    &lt;dependency&gt;
          &lt;groupId&gt;org.seleniumhq.selenium&lt;/groupId&gt;
          &lt;artifactId&gt;selenium-java&lt;/artifactId&gt;
          &lt;version&gt;2.53.1&lt;/version&gt;
      &lt;/dependency&gt; 
  &lt;dependency&gt;
      &lt;groupId&gt;junit&lt;/groupId&gt;
      &lt;artifactId&gt;junit&lt;/artifactId&gt;
      &lt;version&gt;4.12&lt;/version&gt;
  &lt;/dependency&gt;
    
  
  &lt;dependency&gt;
      &lt;groupId&gt;info.cukes&lt;/groupId&gt;
      &lt;artifactId&gt;cucumber-java&lt;/artifactId&gt;
      &lt;version&gt;1.2.5&lt;/version&gt;
  &lt;/dependency&gt;
  
  &lt;dependency&gt;
      &lt;groupId&gt;info.cukes&lt;/groupId&gt;
      &lt;artifactId&gt;cucumber-junit&lt;/artifactId&gt;
      &lt;version&gt;1.2.4&lt;/version&gt;
  &lt;/dependency&gt;
  &lt;/dependencies&gt;
  &lt;/project&gt;
  </code></pre>
  <p><strong>Smoke.java</strong></p>
  <pre><code>public class Smoke {
      WebDriver driver;
      @Given(&quot;^open fireFox and start application$&quot;)
      public void open_fireFox_and_start_application() throws Throwable {
          driver=new FirefoxDriver();
          driver.manage().timeouts().implicitlyWait(20, TimeUnit.SECONDS);
          driver.manage().window().maximize();
          driver.get(&quot;https://testweb.com&quot;);
          
      }
  
      @When(&quot;^I click on Login$&quot;)
      public void I_click_on_Login() throws Throwable {
          driver.findElement(By.xpath(&quot;//a[contains(.,'Login')]&quot;)).click();
          
  
      }
  
      @When(&quot;^enter valid \&quot;([^\&quot;]*)\&quot; and valid \&quot;([^\&quot;]*)\&quot;$&quot;)
      public void enter_valid_and_valid(String un, String pwd) throws Throwable {
          driver.findElement(By.id(&quot;Username&quot;)).sendKeys(un);
          driver.findElement(By.id(&quot;Password&quot;)).sendKeys(pwd);
          
      }
  
      @Then(&quot;^Click on Login$&quot;)
      public void Click_on_Login() throws Throwable {
          driver.findElement(By.id(&quot;loginUser&quot;)).click();
          
      }
      @Then(&quot;^User should be able to login successfully$&quot;)
      public void User_should_be_able_to_login_successfully() throws Throwable {
          
         
      }
  </code></pre>
  <p>These above are the test runner,feature file,Smoke test class.
  Its throwing an Initilization error.I am new to Cucumber and recheck all the maven dependency ,its correct only.But even also its giving error</p>
  <p><a href="https://i.stack.imgur.com/pc1Zv.png" rel="nofollow noreferrer">enter image description here</a></p>