title: Why maven build is failing with error: "package com.microsoft.jdbc.sqlserver does not exist"?
body: <p>I have created project want to deploy it using <strong>Jenkins</strong> and <strong>Git</strong>. I created maven project and added all the dependencies required.
  My one of class contains following code-</p>
  
  <pre><code>try {
      DriverManager.registerDriver(new com.microsoft.jdbc.sqlserver.SQLServerDriver());
  } catch(Exception e) {
      System.out.println("Problem registering JDBC driver");
  }
  </code></pre>
  
  <p>and indicates error at <strong><em>com.microsoft.jdbc.sqlserver.SQLServerDriver()</em></strong> this line like not able to find <strong>com.microsoft</strong> package.</p>
  
  <p>I have added maven dependency for Microsoft server driver in POM file-</p>
  
  <pre><code>&lt;dependency&gt;
      &lt;groupId&gt;com.microsoft.sqlserver&lt;/groupId&gt;
      &lt;artifactId&gt;mssql-jdbc&lt;/artifactId&gt;
      &lt;version&gt;6.4.0.jre8&lt;/version&gt;
      &lt;scope&gt;test&lt;/scope&gt;
  &lt;/dependency&gt;
  </code></pre>
  
  <p>Now when i try to run that project with <strong>clean install</strong> it gives error as: </p>
  
  <blockquote>
    <p>package com.microsoft.jdbc.sqlserver does not exist</p>
  </blockquote>
  
  <p>and fails the build.<br>
  What should I do to remove this error and run my project successfully?</p>