[fpc-devel] last change to xmlreporter.pas (part of fpcUnit) not working

Dean Zobec dezobec at tin.it
Mon Oct 2 19:14:33 CEST 2006


Graeme Geldenhuys ha scritto:
> Hi,
> 
> I got an update of FPC 2.1.1 today, and my fpcUnit test results are
> not correct anymore. The XML test listener (xmlreporter.pas) is not
> writing the Failures correctly.  It keeps creating new (duplicate)
> list nodes for each Failure.  The Error nodes are working fine.
> 
> See a snippet of my output (tested both under the GUI Test Runner and
> the Text Test Runner).
> 
> Notice that there are duplicate ListOfFailures nodes, when there
> should only be one.  The errors are correct, because their is only one
> ListOfErrors node created.

Sorry for that, but I'm unable to reproduce the problem, seems that my
code is working ok. The change in xmlreporter was so simple that I
didn't even bother to write tests for it, I will write them now! :) Can
you send me the source of the runner you are using as well as a simple
suite of tests that creates the problem, so that I can run them and see
what's happening? I need to reproduce the bug to be able to fix it.

Dean

> 
> -------------------------------------------
> ....snip....
>  <ListOfFailures>
>    <Failure>
>      <Message>TTestTIUtils.tiFloatToCurrency: Failed on 4 expected:
> <$ 0.01> but was: <$ 0.00></Message>
>      <ExceptionClass>EAssertionFailedError</ExceptionClass>
>      <ExceptionMessage>Failed on 4 expected: <$ 0.01> but was:
> <$ 0.00></ExceptionMessage>
>    </Failure>
>  </ListOfFailures>
>  <ListOfFailures>
>    <Failure>
>      <Message>TTestTIUtils.tiFloatToCurrencyHide0: Failed on 4
> expected: <$ 0.01> but was: <$ 0.00></Message>
>      <ExceptionClass>EAssertionFailedError</ExceptionClass>
>      <ExceptionMessage>Failed on 4 expected: <$ 0.01> but was:
> <$ 0.00></ExceptionMessage>
>    </Failure>
>  </ListOfFailures>
>  <ListOfErrors>
>    <Error>
>      <Message>TTestTIUtils.tiGetComputerName: Access violation</Message>
>      <ExceptionClass>EAccessViolation</ExceptionClass>
>      <ExceptionMessage>Access violation</ExceptionMessage>
>      <SourceUnitName>./include/lclintf.inc</SourceUnitName>
>      <LineNumber>213</LineNumber>
>      <FailedMethodName>GETCONTROLCONSTRAINTS</FailedMethodName>
>    </Error>
>    <Error>
>      <Message>TTestTIUtils.tiGetTempDir: Access violation</Message>
>      <ExceptionClass>EAccessViolation</ExceptionClass>
>      <ExceptionMessage>Access violation</ExceptionMessage>
>      <SourceUnitName>./include/lclintf.inc</SourceUnitName>
>      <LineNumber>213</LineNumber>
>      <FailedMethodName>GETCONTROLCONSTRAINTS</FailedMethodName>
>    </Error>
>    <Error>
>      <Message>TTestTIUtils.tiGetUserName: Access violation</Message>
>      <ExceptionClass>EAccessViolation</ExceptionClass>
>      <ExceptionMessage>Access violation</ExceptionMessage>
>      <SourceUnitName>./include/lclintf.inc</SourceUnitName>
>      <LineNumber>213</LineNumber>
>      <FailedMethodName>GETCONTROLCONSTRAINTS</FailedMethodName>
>    </Error>
> ....snip....
> -------------------------------------------
> 
> Regards,
>  - Graeme -
> 
> 




More information about the fpc-devel mailing list