I've got standart maven folder structure:
src/main/java
src/main/resources
src/test/java
src/test/resources
My appicationContext contains following:
<!-- load properties files -->
<context:property-placeholder location="classpath*:*.properties"/>
I have defined 2 hibernate.properties
files - one for src/main/resources
and one for src/ test/resources
. I have expected that when I will run tests my test hibernate.properties
will override production hibernate.properties
. Instead of that both files are loaded and production version is used:
Loading properties file from file [D:\projects\video_crawler_v3\out\test\core\hibernate.properties]
Loading properties file from file [D:\projects\video_crawler_v3\out\production\core\hibernate.properties]
How can I correctly setup my properties files? I'm using Intellij IDEA to compile and run tests