This same statement works just fine in my actual application (web service):
InputStream is = ServiceUtils.class.getResourceAsStream(
"file:/C:/Users/withheld/workspace/myproj/src/main/webapp/WEB-INF/classes/myproj.properties");
But inside a JUnit test module, it just keeps returning null.
Why?
At first, I thought this was a classpath issue, so I added a path as described here.
But that didn't help.
So, I forced a brute absolute path, using the method described in this other SO thread.
But it still returning null.
What am I doing wrong?