On Fri, Jun 22, 2012 at 5:19 PM, Jacob Kjome <[email protected]> wrote:
> This test is supposed to be verifying default initialization.  Given that
> the test method is  called "propertiesTest()", it presumes there to be a
> log4j.properties file in the default package somewhere on the classpath at
> test startup.  This must be so because it expects an appender specifically
> named "D3".

> ...And my hunch is confirmed.  Take a look at...
> https://svn.apache.org/repos/asf/logging/log4j/branches/log4j12-bz53299/core/src/test/run-tests.bat

> I suspect the previous build did something akin to what run-tests.bat is
> doing in order to ensure test passage.  The same technique may very well
> need to be duplicated in the new build.

Actually this test did not run with the old pom.xml, it was excluded
(to be more specific it was not included).
And I did not find something which were running the tests in
build.xml. Currently I believe these tests did never run in Gump and
were only triggered manually. That said, there is (unfortunately)
nothing which I can copy.

I did not see anything from Junit which might help us here.

For testing purposes i just created: /src/test/resources/log4j.properties
It does only interfere with XMLLayoutTestCase, the others run fine.

If we would create that property file, the test case cannot run with
xml at the same time. So this is only a 50% solution.

I will remove these tests from the build for now, marking them with // TODO

Thanks for you great help so far!!! I knew you are the right person to ask. :-)


Cheers




>
>
> Jake
>
>
>
> On Fri, 22 Jun 2012 11:57:00 +0200
>  Christian Grobmeier <[email protected]> wrote:
>>
>> Hello guys,
>>
>> I am looking at the build-branch:
>> https://svn.apache.org/repos/asf/logging/log4j/branches/log4j12-bz53299
>>
>> This testcase:
>> org.apache.log4j.defaultInit.TestCase3
>>
>> it fails, because it tells me the root logger is not configured.
>> Actually it looks like this TestCase is wrong, because we get a
>> RootLogger back configured with a NOPLoggerRepository, which returns
>> "not configured".
>>
>> Like:
>> repositorySelector = new DefaultRepositorySelector(new
>> NOPLoggerRepository());
>>
>> I am doubting my analysis is correct. Therefore I wonder what should
>> happen when the testcase runs.
>>
>> Any ideas? Probably Jacob - you usually know very well about the
>> default behavior, could you look at this example?
>>
>> Here is the code:
>>
>> https://svn.apache.org/repos/asf/logging/log4j/branches/log4j12-bz53299/core/src/test/java/org/apache/log4j/defaultInit/TestCase3.java
>>
>> Cheers
>> Christian
>>
>>
>>
>> --
>> http://www.grobmeier.de
>> https://www.timeandbill.de
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: [email protected]
>> For additional commands, e-mail: [email protected]
>>
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
>



-- 
http://www.grobmeier.de
https://www.timeandbill.de

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to