title: FileNotFoundException - java test resources
body: <p>I am writing <code>junit</code> tests, where I need to read a file from <code>src/test/resources</code></p>
  
  <p>I have a following code in my <code>src/test/java/some_packages/UserTests</code>:</p>
  
  <pre><code>InputStream inputStream = new FileInputStream(new File("abc.txt"));
  </code></pre>
  
  <p>The file is of course present, but when I run my test I get <code>java.io.FileNotFoundException: abc.txt (No such file or directory)</code></p>
  
  <p>I marked resources folder as test resources in intellij</p>