*autotest case.
This commit is contained in:
@@ -2,13 +2,21 @@
|
||||
<?php
|
||||
include dirname(dirname(dirname(__FILE__))) . '/lib/init.php';
|
||||
|
||||
/**
|
||||
|
||||
title=测试 programModel::getInvolvedPrograms();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
*/
|
||||
|
||||
class Tester
|
||||
{
|
||||
public function __construct($user)
|
||||
{
|
||||
global $tester;
|
||||
|
||||
su('admin');
|
||||
su($user);
|
||||
$this->program = $tester->loadModel('program');
|
||||
}
|
||||
|
||||
@@ -20,12 +28,6 @@ class Tester
|
||||
|
||||
$t = new Tester('admin');
|
||||
|
||||
/**
|
||||
|
||||
title=测试 programModel::getInvolvedPrograms();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
*/
|
||||
/* GetInvolvedPrograms($account). */
|
||||
r($t->getInvolvedPrograms('admin')) && p('122') && e('122'); // 查看用户admin可以看到的项目和执行id列表
|
||||
r($t->getInvolvedPrograms('test2')) && p('1;122') && e('1;122'); // 查看用户test2可以看到的项目和执行id列表
|
||||
|
||||
Reference in New Issue
Block a user