[ticket/634] Increase test coverage of acp module

B3P-634
This commit is contained in:
Marc Alexander
2015-06-22 16:59:14 +02:00
parent 0ea94ae9c8
commit b805ce2e5f
10 changed files with 79 additions and 14 deletions

View File

@@ -29,10 +29,15 @@ class template
$this->data[$row] = array();
}
$index = (sizeof($this->data[$row])) ? sizeof($this->data[$row]) : 0;
foreach ($values as $key => $column)
{
$this->test_case->assertArrayNotHasKey($key, $this->data[$row]);
$this->data[$row][$key] = $column;
if (!isset($this->data[$row][$index]))
{
$this->data[$row][$index] = array();
}
$this->data[$row][$index][$key] = $column;
}
}
@@ -63,4 +68,9 @@ class template
{
unset($this->data[$key]);
}
public function get_row($row)
{
return $this->data[$row];
}
}