title: spring boot using logback-test.xml instead of logback.xml
body: <p>I have a gradle project and the structure looks like this</p>
  
  <pre><code>&gt;
  &gt; main (one project)
  &gt; shared (another project)
  &gt; api 
  &gt;&gt; shared2 (another project)
  </code></pre>
  
  <p>main project depends on both shared and shared2 projects. Both shared and shared2 projects have a logback-test.xml in their src/<code>test</code>/resources folder and the main project has a logback.xml in its src/<code>main</code>/resources folder.</p>
  
  <p>When I run the main project in eclipse using its main Application class I am expecting that only logback.xml is loaded in classpath. Instead I see warnings that multiple slf4j bindings are found and more importantly the logging settings are being applied from the logback-test.xml instead of logback.xml. Here is the folder structure for further clarification</p>
  
  <pre><code>&gt;
  &gt; main
  &gt; &gt; src/main/resources
  &gt; &gt; &gt; logback.xml
  &gt; shared
  &gt; &gt; src/test/resources
  &gt; &gt; &gt; logback-test.xml
  &gt; api/shared2
  &gt; &gt; src/test/resources
  &gt; &gt; &gt; logback-test.xml
  </code></pre>
  
  <p>In both logback-test.xml files I have enabled org.springframework debugging at DEBUG level and in logback.xml its set at INFO level. When I start the application I see the spring DEBUG logs.</p>
  
  <p>Here is the sample github project
  <a href="https://github.com/adeelmahmood/logback-test-conf-issue" rel="noreferrer">https://github.com/adeelmahmood/logback-test-conf-issue</a></p>