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