TeamCity
class TeamCity extends ResultPrinter (View source)
A TestListener that generates a logfile of the test execution using the TeamCity format (for use with PhpStorm, for instance).
Constants
EVENT_TEST_START |
|
EVENT_TEST_END |
|
EVENT_TESTSUITE_START |
|
EVENT_TESTSUITE_END |
|
COLOR_NEVER |
|
COLOR_AUTO |
|
COLOR_ALWAYS |
|
COLOR_DEFAULT |
|
Properties
protected bool | $autoFlush | If true, flush output after every write. | from Printer |
protected resource | $out | from Printer | |
protected string | $outTarget | from Printer | |
protected int | $column | from ResultPrinter | |
protected int | $maxColumn | from ResultPrinter | |
protected bool | $lastTestFailed | from ResultPrinter | |
protected int | $numAssertions | from ResultPrinter | |
protected int | $numTests | from ResultPrinter | |
protected int | $numTestsRun | from ResultPrinter | |
protected int | $numTestsWidth | from ResultPrinter | |
protected bool | $colors | from ResultPrinter | |
protected bool | $debug | from ResultPrinter | |
protected bool | $verbose | from ResultPrinter |
Methods
Constructor.
No description
Formats a buffer with a specified ANSI color sequence if colors are enabled.
Writes a buffer out with a color sequence if colors are enabled.
Writes progress with a color sequence if colors are enabled.
Details
in ResultPrinter at line 143
__construct(mixed $out = null, bool $verbose = false, string $colors = self::COLOR_DEFAULT, bool $debug = false, int|string $numberOfColumns = 80, bool $reverse = false)
Constructor.
incrementalFlush()
Performs a safe, incremental flush.
Do not confuse this function with the flush() function of this class, since the flush() function may close the file being written to, rendering the current object no longer usable.
setAutoFlush(bool $autoFlush)
Set auto-flushing mode.
If set, incremental flushes will be done after each write. This should not be confused with the different effects of this class' flush() method.
at line 59
printResult(TestResult $result)
in ResultPrinter at line 214
protected
printDefects(array $defects, string $type)
in ResultPrinter at line 253
protected
printDefect(TestFailure $defect, int $count)
in ResultPrinter at line 263
protected
printDefectHeader(TestFailure $defect, int $count)
in ResultPrinter at line 277
protected
printDefectTrace(TestFailure $defect)
in ResultPrinter at line 290
protected
printErrors(TestResult $result)
in ResultPrinter at line 298
protected
printFailures(TestResult $result)
in ResultPrinter at line 306
protected
printWarnings(TestResult $result)
in ResultPrinter at line 314
protected
printIncompletes(TestResult $result)
in ResultPrinter at line 322
protected
printRisky(TestResult $result)
in ResultPrinter at line 330
protected
printSkipped(TestResult $result)
in ResultPrinter at line 335
protected
printHeader()
in ResultPrinter at line 343
protected
printFooter(TestResult $result)
in ResultPrinter at line 419
printWaitPrompt()
at line 110
addFailure(Test $test, AssertionFailedError $e, float $time)
A failure occurred.
at line 52
protected
writeProgress(string $progress)
in ResultPrinter at line 599
protected
writeNewLine()
in ResultPrinter at line 614
protected string
formatWithColor(string $color, string $buffer)
Formats a buffer with a specified ANSI color sequence if colors are enabled.
in ResultPrinter at line 647
protected
writeWithColor(string $color, string $buffer, bool $lf = true)
Writes a buffer out with a color sequence if colors are enabled.
in ResultPrinter at line 662
protected
writeProgressWithColor(string $color, string $buffer)
Writes progress with a color sequence if colors are enabled.