* fix the bug for testtask(runcase, results and create Bug).
This commit is contained in:
@@ -208,7 +208,7 @@ class testtaskModel extends model
|
||||
$caseResult = 'pass';
|
||||
if(!$this->post->passall)
|
||||
{
|
||||
if(isset($this->post->steps))
|
||||
if($this->post->steps)
|
||||
{
|
||||
foreach($this->post->steps as $stepID => $stepResult)
|
||||
{
|
||||
@@ -226,7 +226,7 @@ class testtaskModel extends model
|
||||
}
|
||||
|
||||
/* Create result of every step. */
|
||||
if(isset($this->post->steps))
|
||||
if($this->post->steps)
|
||||
{
|
||||
foreach($this->post->steps as $stepID =>$stepResult)
|
||||
{
|
||||
|
||||
@@ -27,15 +27,21 @@
|
||||
<th class='w-p20'><?php echo $lang->testcase->real;?></th>
|
||||
</tr>
|
||||
<?php foreach($run->case->steps as $key => $step):?>
|
||||
<?php $stepResult = (object)$result->stepResults[$step->id];?>
|
||||
<?php $stepResult = ''; if(!empty($result->stepResults)) $stepResult = (object)$result->stepResults[$step->id];?>
|
||||
<tr>
|
||||
<th><?php echo $key + 1;?></th>
|
||||
<td><?php echo nl2br($step->desc);?></td>
|
||||
<td><?php echo nl2br($step->expect);?></td>
|
||||
<?php if(!empty($result->stepResults)):?>
|
||||
<td class='<?php echo $stepResult->result;?> a-center'><?php echo $lang->testcase->resultList[$stepResult->result];?></td>
|
||||
<td><?php echo $stepResult->real;?></td>
|
||||
</tr>
|
||||
<?php if($stepResult->result == 'blocked' or $stepResult->result == 'fail') break;?>
|
||||
<?php else:?>
|
||||
<td></td>
|
||||
<td></td>
|
||||
</tr>
|
||||
<?php endif;?>
|
||||
<?php endforeach;?>
|
||||
</table>
|
||||
<?php endforeach;?>
|
||||
|
||||
Reference in New Issue
Block a user