Reputation: 96521
One my the mock up testing files i have is loaded by
file = new TestData("src/main/resources/sample.json");
Unfortunately it is not found, while it is there.
In Maven project, is path i am using correct?
Upvotes: 2
Views: 3582
Reputation: 9069
After the project is compiled or packaged, the resources which is stored at the "src/main/resources" will be collected and put to the default package.
You may see further details as the following path/file.
If you would like to access them, please use only their name, e.g. "sample.json".
I hope this may help to clarify your issue.
Regards,
Charlee Ch.
Upvotes: 4