Ticket #254 (closed enhancement: fixed)

Opened 21 months ago

Last modified 7 months ago

Add extra debug resultformatter to the simpletest task

Reported by: tarjei@… Owned by: hans
Priority: major Milestone: 2.4.0RC1
Component: phing-tasks-ext Version: devel
Keywords: simpletest Cc:

Description

When I use the simpletest task it often irritates me that it doesn't report which testcase and -method it runs before after the test case is finished. If php segfaults or explodes in another way, I got no way to track which testcase failed.

I have therefore created the following patch that prints out the testcase name before it runs and also prints a list of failed testcases when the task is finished.

The patch is against current trunk, but I have only tested it with 2.3.0.

Attachments

SimpleTestTask.php.patch Download (2.0 KB) - added by tarjei@… 17 months ago.
SimpleTestDebugResultFormatter.php Download (3.5 KB) - added by tarjei@… 17 months ago.

Change History

in reply to: ↑ description   Changed 17 months ago by anonymous

Replying to tarjei@nu.no:

Where's the attachment :( That's something I'm interested in and I'd rather use your patch than re-create it.

When I use the simpletest task it often irritates me that it doesn't report which testcase and -method it runs before after the test case is finished. If php segfaults or explodes in another way, I got no way to track which testcase failed. I have therefore created the following patch that prints out the testcase name before it runs and also prints a list of failed testcases when the task is finished. The patch is against current trunk, but I have only tested it with 2.3.0.

Changed 17 months ago by tarjei@…

Changed 17 months ago by tarjei@…

  Changed 17 months ago by anonymous

I think I have added the complete patch in those two attachments. Usage:

<simpletest haltonerror="yes" haltonfailure="yes">
      <formatter type="debug" usefile="false" />
      <fileset dir="${project.basedir}/configreader/tests">
...

  Changed 17 months ago by mrook

(In [428]) Refs #254 - add debug result formatter to simpletest task

  Changed 17 months ago by mrook

  • status changed from new to closed
  • resolution set to fixed

This bug has been fixed in the SVN tree, revision r428.

Thank you for the report, and for helping us make Phing better!

  Changed 16 months ago by anonymous

Getting errors:

[wrapped: Formatter 'debug' not implemented]

  Changed 16 months ago by good.midget@…

Just wanted to get my email in here so I can be CC'd on responses

  Changed 16 months ago by mrook

(In [429]) Refs #254 - add debug formatter to SimpleTestFormatterElement::setType

Add/Change #254 (Add extra debug resultformatter to the simpletest task)

Author


E-mail address and user name can be saved in the Preferences.


Action
as closed
Next status will be 'reopened'
 
Note: See TracTickets for help on using tickets.