title: How to fix error not found plugin maven-surefire-plugin >= 2.20 on IntelliJ
body: <p>I tried to migrate to java 11. But when I change the version of plugin maven-surefire-plugin to 2.22.2 that supports java 11, maven or IntelliJ can not find it:</p>
  
  <p><img src="https://i.stack.imgur.com/H0Yrx.png" alt="enter image description here"> </p>
  
  <p>I tried with other versions >= 2.20, but had same error. 
  I tried to fix it:</p>
  
  <ol>
  <li>Firstly, invalidate caches and restart IntelliJ, then reimport maven. But still error.</li>
  <li>I deleted all directories in ~/.m2/repository/org/apache/maven/plugins, and then reimport maven. But maven imported plugin maven-surefire-plugin version 2.19.1 automatically, not imported version 2.22.2 (:</li>
  </ol>
  
  <p><img src="https://i.stack.imgur.com/n0Pik.png" alt="enter image description here"></p>
  
  <ul>
  <li>Update: I installed maven-surefire-plugin version 2.22.2 successfully by maven command line: <strong>mvn install</strong>. It downloaded the plugin but IntelliJ still has the error. I tried to invalidate caches and restart IntelliJ, it worked.</li>
  </ul>
  
  <p>Thanks @Andrey for the great suggestion!</p>