Changeset 316
- Timestamp:
- 12/10/07 08:51:27 (1 year ago)
- Files:
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
branches/2.3/classes/phing/tasks/ext/phpunit/PHPUnitTask.php
r305 r316 40 40 private $haltonerror = false; 41 41 private $haltonfailure = false; 42 private $haltonincomplete = false; 43 private $haltonskipped = false; 44 private $errorproperty; 42 45 private $failureproperty; 43 private $errorproperty; 46 private $incompleteproperty; 47 private $skippedproperty; 44 48 private $printsummary = false; 45 49 private $testfailed = false; … … 132 136 } 133 137 138 function setErrorproperty($value) 139 { 140 $this->errorproperty = $value; 141 } 142 134 143 function setFailureproperty($value) 135 144 { … … 137 146 } 138 147 139 function setErrorproperty($value) 140 { 141 $this->errorproperty = $value; 148 function setIncompleteproperty($value) 149 { 150 $this->incompleteproperty = $value; 151 } 152 153 function setSkippedproperty($value) 154 { 155 $this->skippedproperty = $value; 142 156 } 143 157 … … 150 164 { 151 165 $this->haltonfailure = $value; 166 } 167 168 function setHaltonincomplete($value) 169 { 170 $this->haltonincomplete = $value; 171 } 172 173 function setHaltonskipped($value) 174 { 175 $this->haltonskipped = $value; 152 176 } 153 177 … … 324 348 $this->testfailed = true; 325 349 } 326 } 327 350 } elseif ($retcode == PHPUnitTestRunner::INCOMPLETES) { 351 if ($this->incompleteproperty) { 352 $this->project->setNewProperty($this->incompleteproperty, true); 353 } 354 355 if ($this->haltonincomplete) { 356 $this->testfailed = true; 357 } 358 } elseif ($retcode == PHPUnitTestRunner::SKIPPED) { 359 if ($this->skippedproperty) { 360 $this->project->setNewProperty($this->skippedproperty, true); 361 } 362 363 if ($this->haltonskipped) { 364 $this->testfailed = true; 365 } 366 } 328 367 } 329 368 branches/2.3/classes/phing/tasks/ext/phpunit/PHPUnitTestRunner.php
r276 r316 37 37 const FAILURES = 1; 38 38 const ERRORS = 2; 39 const INCOMPLETES = 3; 40 const SKIPPED = 4; 39 41 40 42 private $test = NULL; … … 117 119 $this->retCode = self::ERRORS; 118 120 } 119 120 else if ($res->failureCount() != 0 || $res->notImplementedCount() != 0 || $res->skippedCount() != 0) 121 else if ($res->failureCount() != 0) 121 122 { 122 123 $this->retCode = self::FAILURES; 124 } 125 else if ($res->notImplementedCount() != 0) 126 { 127 $this->retCode = self::INCOMPLETES; 128 } 129 else if ($res->skippedCount() != 0) 130 { 131 $this->retCode = self::SKIPPED; 123 132 } 124 133 }
