[ http://webtest-community.canoo.com/jira/browse/WT-277?page=all ]
     
Marc Guillemot closed WT-277:
-----------------------------

    Fix Version: future versions
     Resolution: Fixed

Implemented in build 1519.

New format is now:

- for errors:
<error exception="exception class name" filename="/the/file/name" 
line="lineNumber" message="Main message">
  <detail name="..."><![CDATA[some information]]></stacktrace></detail>
  <detail name="..."><![CDATA[some information]]></stacktrace></detail>
  .........
  <stacktrace><![CDATA[the stacktrace]]></stacktrace>
</error>

- for failures: the same except exception and stacktrace

The xsl has been adapted to provide a nice display of these information in html 
files. All the verification steps with an expected and actual value use the 
detail mechanism as well as verifyContent to provide the unified diff.

> Provided additional and better structured information in failure/error 
> messages
> -------------------------------------------------------------------------------
>
>          Key: WT-277
>          URL: http://webtest-community.canoo.com/jira/browse/WT-277
>      Project: WebTest
>         Type: New Feature

>     Versions: 2.1
>     Reporter: Marc Guillemot
>     Assignee: Marc Guillemot
>      Fix For: future versions

>
> Currently the information provided in the html result file in case of 
> error/failure is badly presented and incomplete. This comes from the 
> information available in xml result file.
> Basically this looks like.
> <failure 
> message="/home/marc/EWorkspace/WebTestSVN/selftests/tests/configuration.xml:81:
>  Step[invoke
>  &quot;invoking an unknown page will not work&quot; (1/1)]: HTTP error 404, 
> at: invoke, Step: InvokePage at /hom
> e/marc/EWorkspace/WebTestSVN/selftests/tests/configuration.xml:81:  with 
> (resultFilename=&quot;response_11726780
> 40525_invoke.html&quot;, taskName=&quot;invoke&quot;)"/>
> <error exception="com.canoo.webtest.engine.StepExecutionException" 
> message="No current response avai
> lable! Is previous invoke missing?"><![CDATA[No current response avai
> lable! Is previous invoke 
> missing?"><![CDATA[/home/marc/EWorkspace/WebTestSVN/selftests/tests/configuration.xml:
> 99: No current response available! Is previous invoke missing?, Step: 
> ClickButton at /home/marc/EWorkspace/WebTe
> stSVN/selftests/tests/configuration.xml:99:  with (taskName="clickButton")
>         at com.canoo.webtest.steps.Step.paramCheck(Step.java:410)
> ... the rest of the stack trace ---
> ---]]></error>
> This has following problems:
> - the important error message is lost within too much text (here "HTTP error 
> 404")
> - the location of the failing step can only be found lost within the message
> - additional information can only be contained within the message and 
> therefore can't be properly presented and may cause problem when it contains 
> invalid characters (cf WT-164)
> - the stacktrace is in most of the cases not interesting and just cumbersome
> Following new structure would allow to fix these issues:
> <failure message="..." location="...">
>   <detail name="..."><![CDATA[...]]></detail>
>   <detail name="..."><![CDATA[...]]></detail>
>   ...
> </failure>
> and
> <error exception="..." message="..." location="...">
>   <detail name="..."><![CDATA[...]]></detail>
>   <detail name="..."><![CDATA[...]]></detail>
>   ...
>   <stacktrace><![CDATA[...]]></stacktrace>
> </error>
> where:
> - message only the "main" message
> - location contains the location of the failing step
> - <detail name="...">...</detail> allow to provide "structured" details about 
> the failure/error like expected value, actual value and first diff in a text 
> verification or the available links in a clickLink

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://webtest-community.canoo.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira

_______________________________________________
WebTest mailing list
[email protected]
http://lists.canoo.com/mailman/listinfo/webtest

Reply via email to