I'm using the following call to get a stream so that I can find the filenames of some of my resources.
Thread.currentThread().getContextClassLoader().getResourceAsStream(...)
This works fine when I run my code normally, and it also works fine if I duplicate my resources into my test folder.
How do I avoid this duplication and make my tests (when run through IDEA) use the resources from main?