Merge branch 'master' of https://gitlab.zcorp.cc/easycorp/zentaopms
This commit is contained in:
@@ -1,3 +0,0 @@
|
||||
[submodule "extension/qucheng"]
|
||||
path = extension/qucheng
|
||||
url = https://gitlab.zcorp.cc/easycorp/qucheng.git
|
||||
@@ -24,7 +24,7 @@ class testtasksEntry extends entry
|
||||
|
||||
/* Get all testtasks. */
|
||||
$control = $this->loadController('testtask', 'browse');
|
||||
$productID = $this->param('productID', 0);
|
||||
$productID = $this->param('product', 0);
|
||||
$control->browse($productID, $this->param('branch', ''), ($productID > 0 ? 'local' : 'all') . ',' . $this->param('status', 'totalStatus'), $this->param('order', 'id_desc'), $this->param('total', 0), $this->param('limit', 20), $this->param('page', 1), $this->param('begin', ''), $this->param('end', ''));
|
||||
$data = $this->getData();
|
||||
|
||||
|
||||
+7
-7
@@ -244,8 +244,8 @@ INSERT INTO `zt_dept` (`id`, `name`, `parent`, `path`, `grade`, `order`, `positi
|
||||
INSERT INTO `zt_doclib` (`id`, `type`, `product`, `project`, `execution`, `name`, `acl`, `groups`, `users`, `main`, `collector`, `order`, `deleted`) VALUES
|
||||
(1, 'product', 1, 0, 0, '产品库', 'default', '', '', '1', '', 0, '0'),
|
||||
(2, 'product', 2, 0, 0, '产品库', 'default', '', '', '1', '', 0, '0'),
|
||||
(3, 'project', 0, 0, 1, '项目库', 'default', '', '', '1', '', 0, '0'),
|
||||
(4, 'project', 0, 0, 2, '项目库', 'default', '', '', '1', '', 0, '0'),
|
||||
(3, 'execution', 0, 0, 1, '项目库', 'default', '', '', '1', '', 0, '0'),
|
||||
(4, 'execution', 0, 0, 2, '项目库', 'default', '', '', '1', '', 0, '0'),
|
||||
(5, 'project', 0, 7, 0, '项目主库', 'default', '', '', '1', '', 0, '0');
|
||||
INSERT INTO `zt_history` (`id`, `action`, `field`, `old`, `new`, `diff`) VALUES
|
||||
(1, 14, 'version', '1', '2', ''),
|
||||
@@ -382,11 +382,11 @@ INSERT INTO `zt_product` (`id`, `program`, `name`, `code`, `bind`, `line`, `type
|
||||
(2, 6, '企业内部工时管理系统', 'workhourManage', '0', 0, 'normal', 'normal', '', '', 'productManager', 'testManager', 'productManager', 'open', '', 'productManager', '2012-06-05 11:15:20', '5.2.1', 10, '0');
|
||||
INSERT INTO `zt_productplan` (`id`, `product`, `branch`, `parent`, `title`, `desc`, `begin`, `end`, `order`, `deleted`) VALUES
|
||||
(1, 1, 0, 0, '1.0版本', '开发出企业网站1.0版本。<br />', '2020-06-05', '2021-06-04', '', '0');
|
||||
INSERT INTO `zt_project` (`id`, `project`, `model`, `type`, `product`, `lifetime`, `budget`, `budgetUnit`, `attribute`, `percent`, `milestone`, `output`, `auth`, `parent`, `path`, `grade`, `name`, `code`, `begin`, `end`, `realBegan`, `realEnd`, `days`, `status`, `subStatus`, `statge`, `pri`, `desc`, `version`, `parentVersion`, `planDuration`, `realDuration`, `openedBy`, `openedDate`, `openedVersion`, `lastEditedBy`, `lastEditedDate`, `closedBy`, `closedDate`, `canceledBy`, `canceledDate`, `PO`, `PM`, `QD`, `RD`, `team`, `acl`, `whitelist`, `order`, `deleted`) VALUES
|
||||
(1, 7, '', 'sprint', 'single', 'sprint', '0', 'CNY', '', 0, '0', '', '', 7, ',7,1,', 1, '企业网站第一期', 'coWeb1', '2020-06-05', '2021-12-04', '0000-00-00', '0000-00-00', 391, 'doing', '', '1', '1', '开发企业网站的基本雏形。<br />', 0, 0, 0, 0, '', '0000-00-00 00:00:00', '', '', '0000-00-00 00:00:00', '', '0000-00-00 00:00:00', '', '0000-00-00 00:00:00', 'productManager', 'projectManager', 'testManager', 'productManager', '公司开发团队', 'open', '', 5, '0'),
|
||||
(2, 7, '', 'sprint', 'single', 'sprint', '0', 'CNY', '', 0, '0', '', '', 7, ',7,2,', 1, '企业网站第二期', 'coWebsite2', '2021-06-05', '2022-06-04', '0000-00-00', '0000-00-00', 260, 'wait', '', '1', '1', '', 0, 0, 0, 0, '', '0000-00-00 00:00:00', '', '', '0000-00-00 00:00:00', '', '0000-00-00 00:00:00', '', '0000-00-00 00:00:00', 'productManager', 'projectManager', 'testManager', 'productManager', '公司开发团队', 'open', '', 10, '0'),
|
||||
(7, 0, 'scrum', 'project', 'single', 'sprint', '0', 'CNY', '', 0, '0', '', 'extend', 6, ',6,7,', 2, '企业管理系统', '', '2021-06-05', '2022-06-04', '0000-00-00', '0000-00-00', 0, 'doing', '', '1', '1', '', 0, 0, 0, 0, 'admin', '2021-04-28 11:22:04', '15.0.rc3', 'admin', '2021-04-28 11:22:04', '', '0000-00-00 00:00:00', '', '0000-00-00 00:00:00', '', 'projectManager', '', '', '', 'open', ',tester3,admin', 35, '0'),
|
||||
(6, 0, '', 'program', 'single', 'sprint', '0', 'CNY', '', 0, '0', '', '', 0, ',6,', 1, '企业管理', '', '2021-06-05', '2022-06-04', '0000-00-00', '0000-00-00', 0, 'doing', '', '1', '1', '', 0, 0, 0, 0, 'admin', '2021-04-28 11:22:04', '15.0.rc3', '', '0000-00-00 00:00:00', '', '0000-00-00 00:00:00', '', '0000-00-00 00:00:00', '', '', '', '', '', 'open', '', 30, '0');
|
||||
INSERT INTO `zt_project` (`id`, `project`, `model`, `type`, `lifetime`, `budget`, `budgetUnit`, `attribute`, `percent`, `milestone`, `output`, `auth`, `parent`, `path`, `grade`, `name`, `code`, `begin`, `end`, `realBegan`, `realEnd`, `days`, `status`, `subStatus`, `pri`, `desc`, `version`, `parentVersion`, `planDuration`, `realDuration`, `openedBy`, `openedDate`, `openedVersion`, `lastEditedBy`, `lastEditedDate`, `closedBy`, `closedDate`, `canceledBy`, `canceledDate`, `PO`, `PM`, `QD`, `RD`, `team`, `acl`, `whitelist`, `order`, `deleted`) VALUES
|
||||
(1, 7, '', 'sprint', 'sprint', '0', 'CNY', '', 0, '0', '', '', 7, ',7,1,', 1, '企业网站第一期', 'coWeb1', '2020-06-05', '2021-12-04', '0000-00-00', '0000-00-00', 391, 'doing', '', '1', '开发企业网站的基本雏形。<br />', 0, 0, 0, 0, '', '0000-00-00 00:00:00', '', '', '0000-00-00 00:00:00', '', '0000-00-00 00:00:00', '', '0000-00-00 00:00:00', 'productManager', 'projectManager', 'testManager', 'productManager', '公司开发团队', 'open', '', 5, '0'),
|
||||
(2, 7, '', 'sprint', 'sprint', '0', 'CNY', '', 0, '0', '', '', 7, ',7,2,', 1, '企业网站第二期', 'coWebsite2', '2021-06-05', '2022-06-04', '0000-00-00', '0000-00-00', 260, 'wait', '', '1', '', 0, 0, 0, 0, '', '0000-00-00 00:00:00', '', '', '0000-00-00 00:00:00', '', '0000-00-00 00:00:00', '', '0000-00-00 00:00:00', 'productManager', 'projectManager', 'testManager', 'productManager', '公司开发团队', 'open', '', 10, '0'),
|
||||
(7, 0, 'scrum', 'project', 'sprint', '0', 'CNY', '', 0, '0', '', 'extend', 6, ',6,7,', 2, '企业管理系统', '', '2021-06-05', '2022-06-04', '0000-00-00', '0000-00-00', 0, 'doing', '', '1', '', 0, 0, 0, 0, 'admin', '2021-04-28 11:22:04', '15.0.rc3', 'admin', '2021-04-28 11:22:04', '', '0000-00-00 00:00:00', '', '0000-00-00 00:00:00', '', 'projectManager', '', '', '', 'open', ',tester3,admin', 35, '0'),
|
||||
(6, 0, '', 'program', 'sprint', '0', 'CNY', '', 0, '0', '', '', 0, ',6,', 1, '企业管理', '', '2021-06-05', '2022-06-04', '0000-00-00', '0000-00-00', 0, 'doing', '', '1', '', 0, 0, 0, 0, 'admin', '2021-04-28 11:22:04', '15.0.rc3', '', '0000-00-00 00:00:00', '', '0000-00-00 00:00:00', '', '0000-00-00 00:00:00', '', '', '', '', '', 'open', '', 30, '0');
|
||||
INSERT INTO `zt_projectcase` (`project`, `product`, `case`, `count`, `version`, `order`) VALUES
|
||||
(1, 1, 2, 1, 1, 4),
|
||||
(7, 1, 1, 1, 1, 5),
|
||||
|
||||
Submodule extension/qucheng deleted from 14b5630326
@@ -1370,4 +1370,23 @@ class baseFixer
|
||||
foreach($fields as $key => $fieldName) if(!isset($this->data->$fieldName)) unset($fields[$key]);
|
||||
return $fields;
|
||||
}
|
||||
|
||||
/**
|
||||
* 过滤Emoji表情。
|
||||
* Filter Emoji.
|
||||
*
|
||||
* @param string $fieldName
|
||||
* @access public
|
||||
* @return object
|
||||
*/
|
||||
public function filterEmoji($fieldName){
|
||||
$fields = $this->processFields($fieldName);
|
||||
foreach($fields as $fieldName)
|
||||
{
|
||||
$this->data->$fieldName = preg_replace_callback('/./u', function (array $match){
|
||||
return strlen($match[0]) >= 4 ? '' : $match[0];
|
||||
}, $this->data->$fieldName);
|
||||
}
|
||||
return $this;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -850,6 +850,6 @@ class apiModel extends model
|
||||
private function getDemoData($table, $version)
|
||||
{
|
||||
$file = $this->app->getAppRoot() . 'db' . DS . 'api' . DS . $version . DS . $table;
|
||||
return unserialize(file_get_contents($file));
|
||||
return unserialize(preg_replace_callback('#s:(\d+):"(.*?)";#s', function($match){return 's:'.strlen($match[2]).':"'.$match[2].'";';}, file_get_contents($file)));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1708,8 +1708,8 @@ class block extends control
|
||||
if(common::hasPriv('todo', 'view')) $hasViewPriv['todo'] = true;
|
||||
if(common::hasPriv('task', 'view')) $hasViewPriv['task'] = true;
|
||||
if(common::hasPriv('bug', 'view') and $this->config->vision != 'lite') $hasViewPriv['bug'] = true;
|
||||
if(common::hasPriv('story', 'view') and $this->config->vision != 'lite') $hasViewPriv['story'] = true;
|
||||
if($this->config->URAndSR and common::hasPriv('story', 'view') and $this->config->vision != 'lite') $hasViewPriv['requirement'] = true;
|
||||
if(common::hasPriv('story', 'view') and $this->config->vision != 'lite') $hasViewPriv['story'] = true;
|
||||
if(common::hasPriv('risk', 'view') and $this->config->edition == 'max' and $this->config->vision != 'lite') $hasViewPriv['risk'] = true;
|
||||
if(common::hasPriv('issue', 'view') and $this->config->edition == 'max' and $this->config->vision != 'lite') $hasViewPriv['issue'] = true;
|
||||
if(common::hasPriv('meeting', 'view') and $this->config->edition == 'max' and $this->config->vision != 'lite') $hasViewPriv['meeting'] = true;
|
||||
|
||||
@@ -83,7 +83,7 @@ if(!$selfCall) die(include('./todolist.html.php'));
|
||||
<div class="form-group">
|
||||
<div class="col-sm-12 form-actions no-margin text-center">
|
||||
<?php echo html::hidden('type', 'custom');?>
|
||||
<?php echo html::commonButton($lang->save, "onclick='ajaxCreateTodo(this)'", "btn btn-primary btn-wide");?>
|
||||
<?php echo html::commonButton($lang->save, "onclick='ajaxCreateTodo(this)'", "btn btn-primary btn-wide commitButton");?>
|
||||
<button type="button" class="btn btn-wide todo-form-trigger" data-trigger="false"><?php echo $lang->goback;?></button>
|
||||
</div>
|
||||
</div>
|
||||
@@ -182,6 +182,9 @@ if(!$selfCall) die(include('./todolist.html.php'));
|
||||
setTimeout('clearError()', 2000)
|
||||
return false;
|
||||
}
|
||||
|
||||
$('.commitButton').addClass('disabled');
|
||||
|
||||
$.ajax(
|
||||
{
|
||||
type: "POST",
|
||||
|
||||
@@ -25,7 +25,10 @@ class branch extends control
|
||||
*/
|
||||
public function manage($productID, $browseType = 'active', $orderBy = 'order', $recTotal = 0, $recPerPage = 20, $pageID = 1)
|
||||
{
|
||||
$this->loadModel('product')->setMenu($productID);
|
||||
$product = $this->loadModel('product')->getById($productID);
|
||||
if($product->type == 'normal') $this->locate($this->createLink('product', 'view', "productID=$productID"));
|
||||
|
||||
$this->product->setMenu($productID);
|
||||
$this->session->set('branchManage', $this->app->getURI(true), 'product');
|
||||
$this->branch->changeBranchLanguage($productID);
|
||||
|
||||
|
||||
@@ -504,7 +504,6 @@ class branchModel extends model
|
||||
}
|
||||
else
|
||||
{
|
||||
$branchGroups[$branch->product][0] = $this->lang->branch->main;
|
||||
$branchGroups[$branch->product][$branch->id] = htmlspecialchars_decode($branch->name);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -570,8 +570,8 @@ class bug extends control
|
||||
|
||||
if($projectID)
|
||||
{
|
||||
$project = $this->loadModel('project')->getByID($projectID);
|
||||
if(empty($bugID)) $projects = array($projectID => $project->name);
|
||||
$project = $this->loadModel('project')->getByID($projectID);
|
||||
if(empty($bugID) or $this->app->tab != 'qa') $projects = array($projectID => $project->name);
|
||||
}
|
||||
}
|
||||
elseif($projectID)
|
||||
@@ -580,8 +580,8 @@ class bug extends control
|
||||
$productList = $this->config->CRProduct ? $this->product->getOrderedProducts('all', 40, $projectID) : $this->product->getOrderedProducts('normal', 40, $projectID);
|
||||
foreach($productList as $product) $products[$product->id] = $product->name;
|
||||
|
||||
$project = $this->loadModel('project')->getByID($projectID);
|
||||
if(empty($bugID)) $projects += array($projectID => $project->name);
|
||||
$project = $this->loadModel('project')->getByID($projectID);
|
||||
if(empty($bugID) or $this->app->tab != 'qa') $projects += array($projectID => $project->name);
|
||||
|
||||
/* Set project menu. */
|
||||
if($this->app->tab == 'project') $this->project->setMenu($projectID);
|
||||
@@ -591,8 +591,8 @@ class bug extends control
|
||||
$projects += $this->product->getProjectPairsByProduct($productID, $branch);
|
||||
}
|
||||
|
||||
/* When copying bug, get all project linked to the product. */
|
||||
if(!empty($bugID)) $projects += $this->product->getProjectPairsByProduct($productID, $branch);
|
||||
/* Link all projects to product when copying bug under qa.*/
|
||||
if(!empty($bugID) and $this->app->tab == 'qa') $projects += $this->product->getProjectPairsByProduct($productID, $branch);
|
||||
|
||||
/* Get block id of assinge to me. */
|
||||
$blockID = 0;
|
||||
|
||||
@@ -2332,6 +2332,7 @@ EOD;
|
||||
|
||||
if(empty($acls['views'])) return true;
|
||||
$menu = isset($lang->navGroup->$module) ? $lang->navGroup->$module : $module;
|
||||
if($module == 'my' && $method == 'team') $menu = 'system'; // Fix bug #18642.
|
||||
$menu = strtolower($menu);
|
||||
if($menu != 'qa' and !isset($lang->$menu->menu)) return true;
|
||||
if(($menu == 'my' && $method != 'team')or $menu == 'index' or $module == 'tree') return true;
|
||||
|
||||
@@ -1,12 +1,5 @@
|
||||
$(function()
|
||||
{
|
||||
if($('#urlIframe').size() > 0)
|
||||
{
|
||||
var defaultHeight = $.cookie('windowHeight') - $('#header').height() - $('#footer').height() - $('#mainMenu').height() - 50;
|
||||
$('#urlIframe').height(defaultHeight);
|
||||
setTimeout($.resetToolbarPosition, 50);
|
||||
}
|
||||
|
||||
var isFullscreen = $.cookie('docFullscreen') == 'true';
|
||||
$('body').toggleClass('doc-fullscreen', isFullscreen);
|
||||
$('.side-col').toggleClass('hidden', isFullscreen);
|
||||
@@ -33,6 +26,13 @@ $(function()
|
||||
$(this).find('a[onclick^=deleteFile]').remove();
|
||||
});
|
||||
}
|
||||
|
||||
if($('#urlIframe').size() > 0)
|
||||
{
|
||||
var defaultHeight = $('#mainContent .main-col').height() - 50;
|
||||
$('#urlIframe').height(defaultHeight);
|
||||
setTimeout($.resetToolbarPosition, 50);
|
||||
}
|
||||
})
|
||||
|
||||
function deleteFile(fileID)
|
||||
|
||||
@@ -1826,9 +1826,8 @@ class docModel extends model
|
||||
*/
|
||||
public function getStatisticInfo()
|
||||
{
|
||||
$libIdList = array();
|
||||
$libIdList = $this->getLibIdListByProject($this->session->project);
|
||||
$docIdList = $this->getPrivDocs($libIdList);
|
||||
$allLibs = array_keys($this->getLibs('all'));
|
||||
$docIdList = $this->getPrivDocs($allLibs);
|
||||
|
||||
$today = date('Y-m-d');
|
||||
$lately = date('Y-m-d', strtotime('-3 day'));
|
||||
@@ -2672,6 +2671,7 @@ EOT;
|
||||
$autoloadPage = true;
|
||||
if(!empty($doc) and $doc->type == 'url')
|
||||
{
|
||||
if(!preg_match('/^https?:\/\//', $doc->content)) $doc->content = 'http://' . $doc->content;
|
||||
$parsedUrl = parse_url($doc->content);
|
||||
$urlPort = isset($parsedUrl['port']) ? ':' . $parsedUrl['port'] : '';
|
||||
$urlDomain = $parsedUrl['host'] . $urlPort;
|
||||
|
||||
@@ -135,7 +135,7 @@
|
||||
<li><?php echo html::a($this->createLink('doc', 'browse', "browseType=openedbyme"), '<i class="icon icon-more icon-sm"></i>', '', "title='{$lang->more}'");?></li>
|
||||
</nav>
|
||||
</div>
|
||||
<?php if(!empty($myDocs)):?>
|
||||
<?php if(empty($myDocs)):?>
|
||||
<div class="table-empty-tip">
|
||||
<p><span class="text-muted"><?php echo $lang->doc->noDoc;?></span></p>
|
||||
</div>
|
||||
|
||||
@@ -1631,7 +1631,7 @@ class execution extends control
|
||||
$this->view->productPlans = $productPlans;
|
||||
$this->view->branchGroups = $this->execution->getBranchByProduct(array_keys($linkedProducts), $this->config->systemMode == 'new' ? $execution->project : 0, 'noclosed', $linkedBranchList);
|
||||
$this->view->teamMembers = $this->execution->getTeamMembers($executionID);
|
||||
if($this->config->systemMode == 'new') $this->view->allProjects = $this->project->getPairsByModel($project->model, 0, 'noclosed');
|
||||
if($this->config->systemMode == 'new') $this->view->allProjects = $this->project->getPairsByModel($project->model, 0, 'noclosed', $project->id);
|
||||
$this->display();
|
||||
}
|
||||
|
||||
@@ -1677,8 +1677,9 @@ class execution extends control
|
||||
|
||||
if($this->app->tab == 'project')
|
||||
{
|
||||
$this->project->setMenu($this->session->project);
|
||||
$this->view->project = $this->project->getById($this->session->project);
|
||||
$projectID = $this->session->project;
|
||||
$this->project->setMenu($projectID);
|
||||
$this->view->project = $this->project->getById($projectID);
|
||||
}
|
||||
|
||||
if(!$this->post->executionIDList) return print(js::locate($this->session->executionList, 'parent'));
|
||||
@@ -1716,7 +1717,7 @@ class execution extends control
|
||||
$this->view->position[] = $this->lang->execution->batchEdit;
|
||||
$this->view->executionIDList = $executionIDList;
|
||||
$this->view->executions = $executions;
|
||||
$this->view->allProjects = $this->project->getPairsByModel('all', 0, 'noclosed');
|
||||
$this->view->allProjects = $this->project->getPairsByModel('all', 0, 'noclosed', isset($projectID) ? $projectID : 0);
|
||||
$this->view->pmUsers = $pmUsers;
|
||||
$this->view->poUsers = $poUsers;
|
||||
$this->view->qdUsers = $qdUsers;
|
||||
|
||||
@@ -43,6 +43,7 @@
|
||||
.region .kanban-header-col > .actions {position: relative; right: 5px;}
|
||||
.region .kanban-header-parent-col > .actions {position: absolute; right: 0px;}
|
||||
.region .kanban-header-sub-cols .actions {position: absolute; right: 0px;}
|
||||
.region .kanban.kanban-dragging {overflow: hidden;}
|
||||
|
||||
.region .kanban-lane {position: relative; border-bottom: none!important; min-height: 200px !important}
|
||||
|
||||
|
||||
@@ -295,7 +295,7 @@ function createColumnCreateMenu(options)
|
||||
{
|
||||
if(priv.canCreateTask) items.push({label: taskLang.create, url: $.createLink('task', 'create', 'executionID=' + executionID + "&storyID=0&moduleID=0&taskID=0&todoID=0&extra=regionID=" + regionID + ",laneID=" + laneID + ",columnID=" + col.id, '', true), className: 'iframe', attrs: {'data-toggle': 'modal', 'data-width': '80%'}});
|
||||
if(priv.canBatchCreateTask) items.push({label: taskLang.batchCreate, url: $.createLink('task', 'batchcreate', 'executionID=' + executionID + "&storyID=0&moduleID=0&taskID=0&iframe=0&extra=regionID=" + regionID + ",laneID=" + laneID + ",columnID=" + col.id, '', true), className: 'iframe', attrs: {'data-toggle': 'modal', 'data-width': '80%'}});
|
||||
if(priv.canImportBug && vision == 'rnd') items.push({label: executionLang.importBug, url: $.createLink('execution', 'importBug', 'executionID=' + executionID + "&storyID=0&moduleID=0&taskID=0&todoID=0&extra=laneID=" + laneID + ",columnID=" + col.id, '', true), className: 'iframe', attrs: {'data-toggle': 'modal', 'data-width': '80%'}});
|
||||
if(priv.canImportBug && vision == 'rnd') items.push({label: executionLang.importBug, url: $.createLink('execution', 'importBug', 'executionID=' + executionID + "&storyID=0&moduleID=0&taskID=0&todoID=0&extra=laneID=" + laneID + ",columnID=" + col.id, '', true), className: 'iframe', attrs: {'data-toggle': 'modal', 'data-width': '90%'}});
|
||||
}
|
||||
return items;
|
||||
}
|
||||
|
||||
@@ -836,7 +836,7 @@ function createColumnCreateMenu(options)
|
||||
{
|
||||
if(priv.canCreateTask) items.push({label: taskLang.create, url: $.createLink('task', 'create', 'executionID=' + executionID, '', true), className: 'iframe', attrs: {'data-width': '80%'}});
|
||||
if(priv.canBatchCreateTask) items.push({label: taskLang.batchCreate, url: $.createLink('task', 'batchcreate', 'executionID=' + executionID, '', true), className: 'iframe', attrs: {'data-width': '80%'}});
|
||||
if(priv.canImportBug) items.push({label: executionLang.importBug, url: $.createLink('execution', 'importBug', 'executionID=' + executionID, '', true), className: 'iframe', attrs: {'data-width': '80%'}});
|
||||
if(priv.canImportBug) items.push({label: executionLang.importBug, url: $.createLink('execution', 'importBug', 'executionID=' + executionID, '', true), className: 'iframe', attrs: {'data-width': '90%'}});
|
||||
}
|
||||
return items;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,35 @@
|
||||
(function()
|
||||
{
|
||||
/* Expand or collapse text */
|
||||
function limitText()
|
||||
{
|
||||
var fullText;
|
||||
var limitText;
|
||||
var $text = $(this);
|
||||
var options = $.extend({limitSize: 40, suffix: '…'}, $text.data());
|
||||
var text = $text.text();
|
||||
if(text.length > options.limitSize)
|
||||
{
|
||||
fullText = $text.html();
|
||||
limitText = text.substring(0, options.limitSize) + options.suffix;
|
||||
$text.text(limitText).addClass('limit-text-on');
|
||||
|
||||
var $toggleBtn = options.toggleBtn ? $(options.toggleBtn) : $text.next('.text-limit-toggle');
|
||||
$toggleBtn.text($toggleBtn.data('textExpand'));
|
||||
$toggleBtn.on('click', function()
|
||||
{
|
||||
var isLimitOn = $text.toggleClass('limit-text-on').hasClass('limit-text-on');
|
||||
if(isLimitOn) $text.text(limitText);
|
||||
else $text.html(fullText);
|
||||
$toggleBtn.text($toggleBtn.data(isLimitOn ? 'textExpand' : 'textCollapse'));
|
||||
});
|
||||
}
|
||||
else
|
||||
{
|
||||
(options.toggleBtn ? $(options.toggleBtn) : $text.next('.text-limit-toggle')).hide();
|
||||
}
|
||||
$text.removeClass('hidden');
|
||||
};
|
||||
$.fn.textLimit = function(){return this.each(limitText);};
|
||||
$(function(){$('.text-limit').textLimit();});
|
||||
})();
|
||||
@@ -176,7 +176,7 @@
|
||||
<div class="detail">
|
||||
<h2 class="detail-title"><span class="label-id"><?php echo $execution->id;?></span> <span class="label label-light label-outline"><?php echo $execution->code;?></span> <?php echo $execution->name;?></h2>
|
||||
<div class="detail-content article-content">
|
||||
<div><span class="text-limit" data-limit-size="40"><?php echo $execution->desc;?></span><a class="text-primary text-limit-toggle small" data-text-expand="<?php echo $lang->expand;?>" data-text-collapse="<?php echo $lang->collapse;?>"></a></div>
|
||||
<div><span class="text-limit hidden" data-limit-size="40"><?php echo $execution->desc;?></span><a class="text-primary text-limit-toggle small" data-text-expand="<?php echo $lang->expand;?>" data-text-collapse="<?php echo $lang->collapse;?>"></a></div>
|
||||
<p>
|
||||
<?php if($execution->deleted):?>
|
||||
<span class='label label-danger label-outline'><?php echo $lang->execution->deleted;?></span>
|
||||
|
||||
@@ -617,7 +617,7 @@ class extensionModel extends model
|
||||
foreach($dirs as $dir)
|
||||
{
|
||||
if(!is_dir($appRoot . $dir)) continue;
|
||||
if(!rmdir($appRoot . $dir)) $removeCommands[] = "rmdir $appRoot$dir"; // fix bug #2965
|
||||
if(!rmdir($appRoot . $dir)) $removeCommands[] = PHP_OS == 'Linux' ? "rm -fr $appRoot$dir" : "rmdir $appRoot$dir /s /q";
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -45,8 +45,8 @@
|
||||
<?php $isProjectAdmin = $group->role == 'projectAdmin';?>
|
||||
<?php $disabled = $isProjectAdmin ? 'disabled' : '';?>
|
||||
<?php $lang->group->managepriv = $lang->group->managePrivByGroup;?>
|
||||
<?php common::printIcon('group', 'manageView', "groupID=$group->id", $group, 'list', 'eye', '', "$disabled");?>
|
||||
<?php common::printIcon('group', 'managepriv', "type=byGroup¶m=$group->id", $group, 'list', 'lock');?>
|
||||
<?php common::printIcon('group', 'manageView', "groupID=$group->id", $group, 'list', 'eye', '', $disabled);?>
|
||||
<?php common::printIcon('group', 'managepriv', "type=byGroup¶m=$group->id", $group, 'list', 'lock', '', $disabled);?>
|
||||
<?php $lang->group->managemember = $lang->group->manageMember;?>
|
||||
<?php if($isProjectAdmin):?>
|
||||
<?php common::printIcon('group', 'manageProjectAdmin', "groupID=$group->id", $group, 'list', 'persons');?>
|
||||
|
||||
@@ -23,6 +23,7 @@
|
||||
.region .kanban-header-sub-cols {margin-left:0;}
|
||||
.region .kanban-header-sub-cols .kanban-header-col > .title {max-width: 100% !important;min-width:240px;}
|
||||
.region .sort .region-header {cursor: move;}
|
||||
.region .kanban.kanban-dragging {overflow: hidden;}
|
||||
|
||||
.region .kanban {padding: 0px 5px 10px 10px; min-height: unset; overflow:auto; width: 100%}
|
||||
.region .kanban .form-actions {margin: 0;}
|
||||
|
||||
@@ -0,0 +1,35 @@
|
||||
(function()
|
||||
{
|
||||
/* Expand or collapse text */
|
||||
function limitText()
|
||||
{
|
||||
var fullText;
|
||||
var limitText;
|
||||
var $text = $(this);
|
||||
var options = $.extend({limitSize: 40, suffix: '…'}, $text.data());
|
||||
var text = $text.text();
|
||||
if(text.length > options.limitSize)
|
||||
{
|
||||
fullText = $text.html();
|
||||
limitText = text.substring(0, options.limitSize) + options.suffix;
|
||||
$text.text(limitText).addClass('limit-text-on');
|
||||
|
||||
var $toggleBtn = options.toggleBtn ? $(options.toggleBtn) : $text.next('.text-limit-toggle');
|
||||
$toggleBtn.text($toggleBtn.data('textExpand'));
|
||||
$toggleBtn.on('click', function()
|
||||
{
|
||||
var isLimitOn = $text.toggleClass('limit-text-on').hasClass('limit-text-on');
|
||||
if(isLimitOn) $text.text(limitText);
|
||||
else $text.html(fullText);
|
||||
$toggleBtn.text($toggleBtn.data(isLimitOn ? 'textExpand' : 'textCollapse'));
|
||||
});
|
||||
}
|
||||
else
|
||||
{
|
||||
(options.toggleBtn ? $(options.toggleBtn) : $text.next('.text-limit-toggle')).hide();
|
||||
}
|
||||
$text.removeClass('hidden');
|
||||
};
|
||||
$.fn.textLimit = function(){return this.each(limitText);};
|
||||
$(function(){$('.text-limit').textLimit();});
|
||||
})();
|
||||
@@ -678,12 +678,14 @@ class projectModel extends model
|
||||
/**
|
||||
* Get project pairs by model and project.
|
||||
*
|
||||
* @param string $model all|scrum|waterfall|kanban
|
||||
* @param int $programID
|
||||
* @param string $model all|scrum|waterfall|kanban
|
||||
* @param int $programID
|
||||
* @param string $param noclosed
|
||||
* @param string|int|array $append
|
||||
* @access public
|
||||
* @return array
|
||||
*/
|
||||
public function getPairsByModel($model = 'all', $programID = 0, $param = '')
|
||||
public function getPairsByModel($model = 'all', $programID = 0, $param = '', $append = '')
|
||||
{
|
||||
if(defined('TUTORIAL')) return $this->loadModel('tutorial')->getProjectPairs();
|
||||
|
||||
@@ -696,6 +698,7 @@ class projectModel extends model
|
||||
->beginIF($model != 'all')->andWhere('model')->eq($model)->fi()
|
||||
->beginIF(strpos($param, 'noclosed') !== false)->andWhere('status')->ne('closed')->fi()
|
||||
->beginIF(!$this->app->user->admin)->andWhere('id')->in($this->app->user->view->projects)->fi()
|
||||
->beginIF(!empty($append))->orWhere('id')->in($append)->fi()
|
||||
->orderBy('id_desc')
|
||||
->fetchAll();
|
||||
|
||||
@@ -906,8 +909,8 @@ class projectModel extends model
|
||||
$this->dao->insert(TABLE_PROJECT)->data($project)
|
||||
->autoCheck()
|
||||
->batchcheck($requiredFields, 'notempty')
|
||||
->checkIF(!empty($project->name), 'name', 'unique', "`type`='project' and `parent` = $project->parent")
|
||||
->checkIF(!empty($project->code), 'code', 'unique', "`type`='project'")
|
||||
->checkIF(!empty($project->name), 'name', 'unique', "`type`='project' and `parent` = $project->parent and `model` = '{$project->model}'")
|
||||
->checkIF(!empty($project->code), 'code', 'unique', "`type`='project' and `model` = '{$project->model}'")
|
||||
->checkIF($project->end != '', 'end', 'gt', $project->begin)
|
||||
->exec();
|
||||
|
||||
@@ -1139,8 +1142,8 @@ class projectModel extends model
|
||||
->checkIF($project->begin != '', 'begin', 'date')
|
||||
->checkIF($project->end != '', 'end', 'date')
|
||||
->checkIF($project->end != '', 'end', 'gt', $project->begin)
|
||||
->checkIF(!empty($project->name), 'name', 'unique', "id != $projectID and `type` = 'project' and `parent` = $project->parent")
|
||||
->checkIF(!empty($project->code), 'code', 'unique', "id != $projectID and `type` = 'project'")
|
||||
->checkIF(!empty($project->name), 'name', 'unique', "id != $projectID and `type` = 'project' and `parent` = $project->parent and `model` = '{$project->model}'")
|
||||
->checkIF(!empty($project->code), 'code', 'unique', "id != $projectID and `type` = 'project' and `model` = '{$project->model}'")
|
||||
->where('id')->eq($projectID)
|
||||
->exec();
|
||||
|
||||
@@ -1280,8 +1283,8 @@ class projectModel extends model
|
||||
->checkIF($project->begin != '', 'begin', 'date')
|
||||
->checkIF($project->end != '', 'end', 'date')
|
||||
->checkIF($project->end != '', 'end', 'gt', $project->begin)
|
||||
->checkIF(!empty($project->name), 'name', 'unique', "id != $projectID and `type`='project' and `parent` = $parentID")
|
||||
->checkIF(!empty($project->code), 'code', 'unique', "id != $projectID and `type`='project'")
|
||||
->checkIF(!empty($project->name), 'name', 'unique', "id != $projectID and `type`='project' and `parent` = $parentID and `model` = '{$project->model}'")
|
||||
->checkIF(!empty($project->code), 'code', 'unique', "id != $projectID and `type`='project' and `model` = '{$project->model}'")
|
||||
->where('id')->eq($projectID)
|
||||
->exec();
|
||||
|
||||
|
||||
@@ -125,7 +125,7 @@
|
||||
<div class="detail">
|
||||
<h2 class="detail-title"><span class="label-id"><?php echo $project->id;?></span> <span class="label label-light label-outline"><?php echo $project->code;?></span> <?php echo $project->name;?></h2>
|
||||
<div class="detail-content article-content">
|
||||
<div><span class="text-limit" data-limit-size="40"><?php echo $project->desc;?></span><a class="text-primary text-limit-toggle small" data-text-expand="<?php echo $lang->expand;?>" data-text-collapse="<?php echo $lang->collapse;?>"></a></div>
|
||||
<div><span class="text-limit hidden" data-limit-size="40"><?php echo $project->desc;?></span><a class="text-primary text-limit-toggle small" data-text-expand="<?php echo $lang->expand;?>" data-text-collapse="<?php echo $lang->collapse;?>"></a></div>
|
||||
<p>
|
||||
<?php if($project->deleted):?>
|
||||
<span class='label label-danger label-outline'><?php echo $lang->project->deleted;?></span>
|
||||
|
||||
+18
-1
@@ -200,6 +200,12 @@ class repoModel extends model
|
||||
if(!$this->checkClient()) return false;
|
||||
if(!$this->checkConnection()) return false;
|
||||
|
||||
if($this->post->SCM == 'Gitlab')
|
||||
{
|
||||
if($this->post->gitlabHost == '') dao::$errors['gitlabHost'] = sprintf($this->lang->error->notempty, $this->lang->repo->gitlabHost);
|
||||
if($this->post->gitlabProject == '') dao::$errors['gitlabProject'] = sprintf($this->lang->error->notempty, $this->lang->repo->gitlabProject);
|
||||
}
|
||||
|
||||
$data = fixer::input('post')
|
||||
->setIf($this->post->SCM == 'Gitlab', 'password', $this->post->gitlabToken)
|
||||
->setIf($this->post->SCM == 'Gitlab', 'path', $this->post->gitlabProject)
|
||||
@@ -262,6 +268,12 @@ class repoModel extends model
|
||||
{
|
||||
$repo = $this->getRepoByID($id);
|
||||
|
||||
if($this->post->SCM == 'Gitlab')
|
||||
{
|
||||
if($this->post->gitlabHost == '') dao::$errors['gitlabHost'] = sprintf($this->lang->error->notempty, $this->lang->repo->gitlabHost);
|
||||
if($this->post->gitlabProject == '') dao::$errors['gitlabProject'] = sprintf($this->lang->error->notempty, $this->lang->repo->gitlabProject);
|
||||
}
|
||||
|
||||
$data = fixer::input('post')
|
||||
->setIf($this->post->SCM == 'Gitlab', 'password', $this->post->gitlabToken)
|
||||
->setIf($this->post->SCM == 'Gitlab', 'path', $this->post->gitlabProject)
|
||||
@@ -1149,7 +1161,12 @@ class repoModel extends model
|
||||
{
|
||||
if($this->post->SCM == 'Gitlab') return true;
|
||||
if(!$this->config->features->checkClient) return true;
|
||||
if(!$this->post->client) return true;
|
||||
|
||||
if(!$this->post->client)
|
||||
{
|
||||
dao::$errors['client'] = sprintf($this->lang->error->notempty, $this->lang->repo->client);
|
||||
return false;
|
||||
}
|
||||
|
||||
if(strpos($this->post->client, ' '))
|
||||
{
|
||||
|
||||
@@ -399,7 +399,6 @@ class searchModel extends model
|
||||
public function deleteQuery($queryID)
|
||||
{
|
||||
$this->dao->delete()->from(TABLE_USERQUERY)->where('id')->eq($queryID)->andWhere('account')->eq($this->app->user->account)->exec();
|
||||
echo 'success';
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -546,6 +546,7 @@ $(function()
|
||||
if($('#formType').val() == 'more') expandForm(true);
|
||||
$searchForm.on('click', '.user-query .icon-close', function(e)
|
||||
{
|
||||
e.preventDefault(); // Fix bug #21572.
|
||||
var $query = $(this).closest('.user-query');
|
||||
var queryId = $query.data('queryId');
|
||||
var deleteQueryLink = $.createLink('search', 'deleteQuery', 'queryID=' + queryId);
|
||||
|
||||
@@ -305,7 +305,7 @@
|
||||
?>
|
||||
<td title='<?php echo $moduleTitle?>'><?php echo $printModule?></td>
|
||||
</tr>
|
||||
<?php if($story->type != 'requirement'):?>
|
||||
<?php if($story->type != 'requirement' and $story->parent != -1):?>
|
||||
<tr class='plan-line'>
|
||||
<th><?php echo $lang->story->plan;?></th>
|
||||
<td>
|
||||
|
||||
@@ -216,7 +216,7 @@ class testcase extends control
|
||||
$this->view->browseType = $browseType;
|
||||
$this->view->param = $param;
|
||||
$this->view->cases = $cases;
|
||||
$this->view->branch = !empty($product) and $product->type != 'normal' ? $branch : 0;
|
||||
$this->view->branch = (!empty($product) and $product->type != 'normal') ? $branch : 0;
|
||||
$this->view->branchOption = $branchOption;
|
||||
$this->view->branchTagOption = $branchTagOption;
|
||||
$this->view->suiteList = $this->loadModel('testsuite')->getSuites($productID);
|
||||
|
||||
@@ -71,7 +71,9 @@ class testcaseModel extends model
|
||||
$this->loadModel('file')->saveUpload('testcase', $caseID);
|
||||
$parentStepID = 0;
|
||||
$this->loadModel('score')->create('testcase', 'create', $caseID);
|
||||
foreach($this->post->steps as $stepID => $stepDesc)
|
||||
|
||||
$data = fixer::input('post')->filterEmoji('steps,expects')->get();
|
||||
foreach($data->steps as $stepID => $stepDesc)
|
||||
{
|
||||
if(empty($stepDesc)) continue;
|
||||
$stepType = $this->post->stepType;
|
||||
@@ -81,7 +83,7 @@ class testcaseModel extends model
|
||||
$step->case = $caseID;
|
||||
$step->version = 1;
|
||||
$step->desc = htmlSpecialString($stepDesc);
|
||||
$step->expect = $step->type == 'group' ? '' : htmlSpecialString($this->post->expects[$stepID]);
|
||||
$step->expect = $step->type == 'group' ? '' : htmlSpecialString($data->expects[$stepID]);
|
||||
$this->dao->insert(TABLE_CASESTEP)->data($step)->autoCheck()->exec();
|
||||
if($step->type == 'group') $parentStepID = $this->dao->lastInsertID();
|
||||
if($step->type == 'step') $parentStepID = 0;
|
||||
@@ -741,7 +743,9 @@ class testcaseModel extends model
|
||||
/* Ignore steps when post has no steps. */
|
||||
if($this->post->steps)
|
||||
{
|
||||
foreach($this->post->steps as $stepID => $stepDesc)
|
||||
$data = fixer::input('post')->filterEmoji('steps,expects')->get();
|
||||
|
||||
foreach($data->steps as $stepID => $stepDesc)
|
||||
{
|
||||
if(empty($stepDesc)) continue;
|
||||
$stepType = $this->post->stepType;
|
||||
@@ -751,7 +755,7 @@ class testcaseModel extends model
|
||||
$step->case = $caseID;
|
||||
$step->version = $version;
|
||||
$step->desc = htmlSpecialString($stepDesc);
|
||||
$step->expect = $step->type == 'group' ? '' : htmlSpecialString($this->post->expects[$stepID]);
|
||||
$step->expect = $step->type == 'group' ? '' : htmlSpecialString($data->expects[$stepID]);
|
||||
$this->dao->insert(TABLE_CASESTEP)->data($step)->autoCheck()->exec();
|
||||
if($step->type == 'group') $parentStepID = $this->dao->lastInsertID();
|
||||
if($step->type == 'step') $parentStepID = 0;
|
||||
|
||||
@@ -51,7 +51,7 @@
|
||||
<th class='col-name required'><?php echo $lang->todo->name;?></th>
|
||||
<th class='col-desc<?php echo zget($visibleFields, 'desc', ' hidden');?>'><?php echo $lang->todo->desc;?></th>
|
||||
<th class='col-date<?php echo zget($visibleFields, 'beginAndEnd', ' hidden')?>'><?php echo $lang->todo->beginAndEnd;?></th>
|
||||
<th><div class="checkbox-primary check-all" id="select-all"><label><?php echo $lang->todo->periods['future']?></label></div></th>
|
||||
<th><div class='checkbox-primary check-all<?php echo zget($visibleFields, 'beginAndEnd', ' hidden')?>' style='overflow:visible' id="select-all"><label><?php echo $lang->todo->periods['future']?></label></div></th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
|
||||
@@ -257,8 +257,8 @@ $lang->user->mkdirLinux = <<<EOT
|
||||
<html><head><meta charset='utf-8'></head>
|
||||
<body><table align='center' style='width:700px; margin-top:100px; border:1px solid gray; font-size:14px;'><tr><td style='padding:8px'>
|
||||
<div style='margin-bottom:8px;'>不能创建临时目录,请确认目录<strong style='color:#ed980f'>%s</strong>是否存在并有操作权限。</div>
|
||||
<div style='margin-bottom:8px;'>命令为:<strong style='color:#ed980f'>chmod o=rwx -R %s</strong>。</div>
|
||||
<div style='margin-bottom:8px;'>命令为:<strong style='color:#ed980f'>chmod 777 -R %s</strong>。</div>
|
||||
<div>Can't create tmp directory, make sure the directory <strong style='color:#ed980f'>%s</strong> exists and has permission to operate.</div>
|
||||
<div style='margin-bottom:8px;'>Commond: <strong style='color:#ed980f'>chmod o=rwx -R %s</strong>.</div>
|
||||
<div style='margin-bottom:8px;'>Commond: <strong style='color:#ed980f'>chmod 777 -R %s</strong>.</div>
|
||||
</td></tr></table></body></html>
|
||||
EOT;
|
||||
|
||||
@@ -285,8 +285,8 @@ $lang->user->mkdirLinux = <<<EOT
|
||||
<html><head><meta charset='utf-8'></head>
|
||||
<body><table align='center' style='width:700px; margin-top:100px; border:1px solid gray; font-size:14px;'><tr><td style='padding:8px'>
|
||||
<div style='margin-bottom:8px;'>不能创建临时目录,请确认目录<strong style='color:#ed980f'>%s</strong>是否存在并有操作权限。</div>
|
||||
<div style='margin-bottom:8px;'>命令为:<strong style='color:#ed980f'>chmod o=rwx -R %s</strong>。</div>
|
||||
<div style='margin-bottom:8px;'>命令为:<strong style='color:#ed980f'>chmod 777 -R %s</strong>。</div>
|
||||
<div>A tmp directory cannot be created. Make sure the directory <strong style='color:#ed980f'>%s</strong> exists and you have the right permission.</div>
|
||||
<div style='margin-bottom:8px;'>Commond: <strong style='color:#ed980f'>chmod o=rwx -R %s</strong>.</div>
|
||||
<div style='margin-bottom:8px;'>Commond: <strong style='color:#ed980f'>chmod 777 -R %s</strong>.</div>
|
||||
</td></tr></table></body></html>
|
||||
EOT;
|
||||
|
||||
@@ -257,8 +257,8 @@ $lang->user->mkdirLinux = <<<EOT
|
||||
<html><head><meta charset='utf-8'></head>
|
||||
<body><table align='center' style='width:700px; margin-top:100px; border:1px solid gray; font-size:14px;'><tr><td style='padding:8px'>
|
||||
<div style='margin-bottom:8px;'>不能创建临时目录,请确认目录<strong style='color:#ed980f'>%s</strong>是否存在并有操作权限。</div>
|
||||
<div style='margin-bottom:8px;'>命令为:<strong style='color:#ed980f'>chmod o=rwx -R %s</strong>。</div>
|
||||
<div style='margin-bottom:8px;'>命令为:<strong style='color:#ed980f'>chmod 777 -R %s</strong>。</div>
|
||||
<div>Can't create tmp directory, make sure the directory <strong style='color:#ed980f'>%s</strong> exists and has permission to operate.</div>
|
||||
<div style='margin-bottom:8px;'>Commond: <strong style='color:#ed980f'>chmod o=rwx -R %s</strong>.</div>
|
||||
<div style='margin-bottom:8px;'>Commond: <strong style='color:#ed980f'>chmod 777 -R %s</strong>.</div>
|
||||
</td></tr></table></body></html>
|
||||
EOT;
|
||||
|
||||
@@ -257,8 +257,8 @@ $lang->user->mkdirLinux = <<<EOT
|
||||
<html><head><meta charset='utf-8'></head>
|
||||
<body><table align='center' style='width:700px; margin-top:100px; border:1px solid gray; font-size:14px;'><tr><td style='padding:8px'>
|
||||
<div style='margin-bottom:8px;'>不能创建临时目录,请确认目录<strong style='color:#ed980f'>%s</strong>是否存在并有操作权限。</div>
|
||||
<div style='margin-bottom:8px;'>命令为:<strong style='color:#ed980f'>chmod o=rwx -R %s</strong>。</div>
|
||||
<div style='margin-bottom:8px;'>命令为:<strong style='color:#ed980f'>chmod 777 -R %s</strong>。</div>
|
||||
<div>Can't create tmp directory, make sure the directory <strong style='color:#ed980f'>%s</strong> exists and has permission to operate.</div>
|
||||
<div style='margin-bottom:8px;'>Commond: <strong style='color:#ed980f'>chmod o=rwx -R %s</strong>.</div>
|
||||
<div style='margin-bottom:8px;'>Commond: <strong style='color:#ed980f'>chmod 777 -R %s</strong>.</div>
|
||||
</td></tr></table></body></html>
|
||||
EOT;
|
||||
|
||||
@@ -285,9 +285,9 @@ $lang->user->mkdirLinux = <<<EOT
|
||||
<html><head><meta charset='utf-8'></head>
|
||||
<body><table align='center' style='width:700px; margin-top:100px; border:1px solid gray; font-size:14px;'><tr><td style='padding:8px'>
|
||||
<div style='margin-bottom:8px;'>不能创建临时目录,请确认目录<strong style='color:#ed980f'>%s</strong>是否存在并有操作权限。</div>
|
||||
<div style='margin-bottom:8px;'>命令为:<strong style='color:#ed980f'>chmod o=rwx -R %s</strong>。</div>
|
||||
<div style='margin-bottom:8px;'>命令为:<strong style='color:#ed980f'>chmod 777 -R %s</strong>。</div>
|
||||
<div>Can't create tmp directory, make sure the directory <strong style='color:#ed980f'>%s</strong> exists and has permission to operate.</div>
|
||||
<div style='margin-bottom:8px;'>Commond: <strong style='color:#ed980f'>chmod o=rwx -R %s</strong>.</div>
|
||||
<div style='margin-bottom:8px;'>Commond: <strong style='color:#ed980f'>chmod 777 -R %s</strong>.</div>
|
||||
</td></tr></table></body></html>
|
||||
EOT;
|
||||
|
||||
|
||||
@@ -282,9 +282,9 @@ $lang->user->mkdirLinux = <<<EOT
|
||||
<html><head><meta charset='utf-8'></head>
|
||||
<body><table align='center' style='width:700px; margin-top:100px; border:1px solid gray; font-size:14px;'><tr><td style='padding:8px'>
|
||||
<div style='margin-bottom:8px;'>不能創建臨時目錄,請確認目錄<strong style='color:#ed980f'>%s</strong>是否存在並有操作權限。</div>
|
||||
<div style='margin-bottom:8px;'>命令為:<strong style='color:#ed980f'>chmod o=rwx -R %s</strong>。</div>
|
||||
<div style='margin-bottom:8px;'>命令為:<strong style='color:#ed980f'>chmod 777 -R %s</strong>。</div>
|
||||
<div>Can't create tmp directory, make sure the directory <strong style='color:#ed980f'>%s</strong> exists and has permission to operate.</div>
|
||||
<div style='margin-bottom:8px;'>Commond: <strong style='color:#ed980f'>chmod o=rwx -R %s</strong>.</div>
|
||||
<div style='margin-bottom:8px;'>Commond: <strong style='color:#ed980f'>chmod 777 -R %s</strong>.</div>
|
||||
</td></tr></table></body></html>
|
||||
EOT;
|
||||
|
||||
|
||||
@@ -0,0 +1,404 @@
|
||||
<?php
|
||||
class branchTest
|
||||
{
|
||||
public function __construct()
|
||||
{
|
||||
global $tester;
|
||||
$this->objectModel = $tester->loadModel('branch');
|
||||
}
|
||||
|
||||
/**
|
||||
* Test get name by id.
|
||||
*
|
||||
* @param int $branchID
|
||||
* @param int $productID
|
||||
* @param string $field
|
||||
* @access public
|
||||
* @return object
|
||||
*/
|
||||
public function getByIdTest($branchID, $productID = 0, $field = 'name')
|
||||
{
|
||||
$object = $this->objectModel->getById($branchID, $productID, $field);
|
||||
|
||||
if(dao::isError()) return dao::getError();
|
||||
|
||||
return $object;
|
||||
}
|
||||
|
||||
/**
|
||||
* Test get branch list.
|
||||
*
|
||||
* @param int $productID
|
||||
* @param int $executionID
|
||||
* @param string $browseType
|
||||
* @param bool $withMainBranch
|
||||
* @access public
|
||||
* @return string
|
||||
*/
|
||||
public function getListTest($productID, $executionID = 0, $browseType = 'active', $withMainBranch = true)
|
||||
{
|
||||
$objects = $this->objectModel->getList($productID, $executionID, $browseType, 'order', null, $withMainBranch);
|
||||
|
||||
if(dao::isError()) return dao::getError();
|
||||
|
||||
$ids = '';
|
||||
foreach($objects as $object) $ids .= ',' . $object->id;
|
||||
return $ids;
|
||||
}
|
||||
|
||||
/**
|
||||
* Test get pairs.
|
||||
*
|
||||
* @param int $productID
|
||||
* @param string $params
|
||||
* @param int $executionID
|
||||
* @param string $mergedBranches
|
||||
* @access public
|
||||
* @return string
|
||||
*/
|
||||
public function getPairsTest($productID, $params = '', $executionID = 0, $mergedBranches = '')
|
||||
{
|
||||
$objects = $this->objectModel->getPairs($productID, $params, $executionID, $mergedBranches);
|
||||
|
||||
if(dao::isError()) return dao::getError();
|
||||
|
||||
$ids = '';
|
||||
foreach($objects as $id => $object) $ids .= ',' . $id;
|
||||
return $ids;
|
||||
}
|
||||
|
||||
/**
|
||||
* Test get all pairs.
|
||||
*
|
||||
* @param string $params
|
||||
* @access public
|
||||
* @return int
|
||||
*/
|
||||
public function getAllPairsTest($params = '')
|
||||
{
|
||||
$objects = $this->objectModel->getAllPairs($params);
|
||||
|
||||
if(dao::isError()) return dao::getError();
|
||||
|
||||
return count($objects);
|
||||
}
|
||||
|
||||
/**
|
||||
* Test create a branch.
|
||||
*
|
||||
* @param int $productID
|
||||
* @param array $param
|
||||
* @access public
|
||||
* @return object
|
||||
*/
|
||||
public function createTest($productID, $param = array())
|
||||
{
|
||||
foreach($param as $key => $value) $_POST[$key] = $value;
|
||||
|
||||
$objectID = $this->objectModel->create($productID, $withMerge = false);
|
||||
|
||||
unset($_POST);
|
||||
|
||||
if(dao::isError()) return dao::getError()['name'][0];
|
||||
|
||||
global $tester;
|
||||
$object = $tester->dao->select('*')->from(TABLE_BRANCH)->where('id')->eq($objectID)->fetch();
|
||||
return $object;
|
||||
}
|
||||
|
||||
/**
|
||||
* Test update branch.
|
||||
*
|
||||
* @param array $param
|
||||
* @access public
|
||||
* @return array
|
||||
*/
|
||||
public function updateTest($param)
|
||||
{
|
||||
$branchID = 1;
|
||||
|
||||
$branch = $this->objectModel->getByID($branchID, 0, '');
|
||||
|
||||
$_POST['name'] = $branch->name;
|
||||
$_POST['status'] = $branch->status;
|
||||
$_POST['desc'] = $branch->desc;
|
||||
|
||||
foreach($param as $key => $value) $_POST[$key] = $value;
|
||||
|
||||
$objects = $this->objectModel->update($branchID);
|
||||
|
||||
unset($_POST);
|
||||
|
||||
if(dao::isError()) return dao::getError();
|
||||
|
||||
return $objects;
|
||||
}
|
||||
|
||||
/**
|
||||
* Test batch update branch.
|
||||
*
|
||||
* @param array $param
|
||||
* @access public
|
||||
* @return object
|
||||
*/
|
||||
public function batchUpdateTest($param = array())
|
||||
{
|
||||
global $tester;
|
||||
|
||||
$productID = 45;
|
||||
$branches = $tester->dao->select('*')->from(TABLE_BRANCH)->where('product')->eq($productID)->fetchAll('id');
|
||||
|
||||
$_POST['IDList'] = array('0' => 0, '9' => 9, '10' => 10);
|
||||
$_POST['default'] = 0;
|
||||
$_POST['name'] = array('9' => $branches['9']->name, '10' => $branches['10']->name);
|
||||
$_POST['desc'] = array('9' => $branches['9']->desc, '10' => $branches['10']->desc);
|
||||
$_POST['status'] = array('9' => $branches['9']->status, '10' => $branches['10']->status);
|
||||
|
||||
foreach($param as $key => $value) $_POST[$key] = $value;
|
||||
|
||||
$objects = $this->objectModel->batchUpdate($productID);
|
||||
|
||||
unset($_POST);
|
||||
|
||||
if(dao::isError()) return dao::getError();
|
||||
|
||||
return $objects[9][0];
|
||||
}
|
||||
|
||||
/**
|
||||
* Test close a branch.
|
||||
*
|
||||
* @param int $branchID
|
||||
* @access public
|
||||
* @return object
|
||||
*/
|
||||
public function closeTest($branchID)
|
||||
{
|
||||
$this->objectModel->close($branchID);
|
||||
|
||||
if(dao::isError()) return dao::getError();
|
||||
|
||||
global $tester;
|
||||
$object = $tester->dao->select('*')->from(TABLE_BRANCH)->where('id')->eq($branchID)->fetch();
|
||||
return $object;
|
||||
}
|
||||
|
||||
/**
|
||||
* Test activate a branch.
|
||||
*
|
||||
* @param int $branchID
|
||||
* @access public
|
||||
* @return object
|
||||
*/
|
||||
public function activateTest($branchID)
|
||||
{
|
||||
$this->objectModel->activate($branchID);
|
||||
|
||||
if(dao::isError()) return dao::getError();
|
||||
|
||||
global $tester;
|
||||
$object = $tester->dao->select('*')->from(TABLE_BRANCH)->where('id')->eq($branchID)->fetch();
|
||||
return $object;
|
||||
}
|
||||
|
||||
/**
|
||||
* Test unlink branches for projects when product type is normal.
|
||||
*
|
||||
* @param string $productIDList
|
||||
* @access public
|
||||
* @return int
|
||||
*/
|
||||
public function unlinkBranch4ProjectTest($productIDList)
|
||||
{
|
||||
$this->objectModel->unlinkBranch4Project($productIDList);
|
||||
|
||||
if(dao::isError()) return dao::getError();
|
||||
|
||||
global $tester;
|
||||
$objects = $tester->dao->select('*')->from(TABLE_PROJECTPRODUCT)->where('product')->in($productIDList)->andWhere('branch')->gt(0)->fetchAll();
|
||||
return count($objects);
|
||||
}
|
||||
|
||||
/**
|
||||
* Test link branches for projects when product type is not normal.
|
||||
*
|
||||
* @param int $productID
|
||||
* @access public
|
||||
* @return int
|
||||
*/
|
||||
public function linkBranch4ProjectTest($productID)
|
||||
{
|
||||
$this->objectModel->linkBranch4Project($productID);
|
||||
|
||||
if(dao::isError()) return dao::getError();
|
||||
|
||||
global $tester;
|
||||
$objects = $tester->dao->select('*')->from(TABLE_PROJECTPRODUCT)->where('product')->eq($productID)->andWhere('branch')->gt(0)->fetchAll();
|
||||
return count($objects);
|
||||
}
|
||||
|
||||
/**
|
||||
* Test get branch group by products.
|
||||
*
|
||||
* @param int $products
|
||||
* @param string $params
|
||||
* @param string $appendBranch
|
||||
* @access public
|
||||
* @return string
|
||||
*/
|
||||
public function getByProductsTest($products, $params = '', $appendBranch = '')
|
||||
{
|
||||
$objects = $this->objectModel->getByProducts($products, $params, $appendBranch);
|
||||
|
||||
if(dao::isError()) return dao::getError();
|
||||
|
||||
$ids = '';
|
||||
foreach($objects as $productID => $branches)
|
||||
{
|
||||
$ids .= "$productID:";
|
||||
foreach($branches as $branchID => $branchName) $ids .= ",$branchID";
|
||||
$ids .= ';';
|
||||
}
|
||||
return $ids;
|
||||
}
|
||||
|
||||
/**
|
||||
* Test get product bype by branch.
|
||||
*
|
||||
* @param int $branchID
|
||||
* @access public
|
||||
* @return string
|
||||
*/
|
||||
public function getProductTypeTest($branchID)
|
||||
{
|
||||
$type = $this->objectModel->getProductType($branchID);
|
||||
|
||||
if(dao::isError()) return dao::getError();
|
||||
|
||||
return $type;
|
||||
}
|
||||
|
||||
/**
|
||||
* Test sort branch.
|
||||
*
|
||||
* @param string $branches
|
||||
* @param string $order
|
||||
* @access public
|
||||
* @return string
|
||||
*/
|
||||
public function sortTest($branches, $order = '')
|
||||
{
|
||||
$_POST['orderBy'] = $order;
|
||||
$_POST['branches'] = $branches;
|
||||
|
||||
$this->objectModel->sort();
|
||||
|
||||
unset($_POST);
|
||||
|
||||
if(dao::isError()) return dao::getError();
|
||||
|
||||
global $tester;
|
||||
$objects = $tester->dao->select('*')->from(TABLE_BRANCH)->where('id')->in($branches)->orderBy('order asc')->fetchAll('id');
|
||||
return implode(',', array_keys($objects));
|
||||
}
|
||||
|
||||
/**
|
||||
* Test check branch data.
|
||||
*
|
||||
* @param int $branchID
|
||||
* @access public
|
||||
* @return int
|
||||
*/
|
||||
public function checkBranchDataTest($branchID)
|
||||
{
|
||||
$objects = $this->objectModel->checkBranchData($branchID);
|
||||
|
||||
if(dao::isError()) return dao::getError();
|
||||
|
||||
return $objects ? 1 : 2;
|
||||
}
|
||||
|
||||
/**
|
||||
* Test get branches of product which linked project.
|
||||
*
|
||||
* @param int $projectID
|
||||
* @param int $productID
|
||||
* @access public
|
||||
* @return string
|
||||
*/
|
||||
public function getPairsByProjectProductTest($projectID, $productID)
|
||||
{
|
||||
$objects = $this->objectModel->getPairsByProjectProduct($projectID, $productID);
|
||||
|
||||
if(dao::isError()) return dao::getError();
|
||||
|
||||
$names = '';
|
||||
foreach($objects as $id => $name) $names .= "$id:$name;";
|
||||
return $names;
|
||||
}
|
||||
|
||||
/**
|
||||
* Test display of branch label.
|
||||
*
|
||||
* @param int $productID
|
||||
* @param int $moduleID
|
||||
* @param int $executionID
|
||||
* @access public
|
||||
* @return int
|
||||
*/
|
||||
public function showBranchTest($productID, $moduleID = 0, $executionID = 0)
|
||||
{
|
||||
$show = $this->objectModel->showBranch($productID, $moduleID = 0, $executionID = 0);
|
||||
|
||||
if(dao::isError()) return dao::getError();
|
||||
|
||||
return $show ? 1 : 2;
|
||||
}
|
||||
|
||||
/**
|
||||
* Test change branch language.
|
||||
*
|
||||
* @param int $productID
|
||||
* @access public
|
||||
* @return string
|
||||
*/
|
||||
public function changeBranchLanguageTest($productID)
|
||||
{
|
||||
global $tester;
|
||||
global $lang;
|
||||
|
||||
$filePath = dirname(dirname(dirname(__FILE__))) . DS . 'module' . DS . 'branch' . DS . 'lang' . DS . 'zh-cn.php';
|
||||
include $filePath;
|
||||
|
||||
$this->objectModel->changeBranchLanguage($productID);
|
||||
|
||||
$createLang = $tester->lang->branch->create;
|
||||
|
||||
if(dao::isError()) return dao::getError();
|
||||
|
||||
return $createLang;
|
||||
}
|
||||
|
||||
/**
|
||||
* Test merge multiple branches into one branch.
|
||||
*
|
||||
* @param int $productID
|
||||
* @param string $mergedBranches
|
||||
* @access public
|
||||
* @return int
|
||||
*/
|
||||
public function mergeBranchTest($productID, $mergedBranches, $param)
|
||||
{
|
||||
foreach($param as $key => $value) $_POST[$key] = $value;
|
||||
|
||||
$objectID = $this->objectModel->mergeBranch($productID, $mergedBranches);
|
||||
|
||||
unset($_POST);
|
||||
|
||||
if(dao::isError()) return dao::getError();
|
||||
|
||||
global $tester;
|
||||
$modules = $tester->dao->select('*')->from(TABLE_MODULE)->where('branch')->eq($objectID)->andWhere('root')->eq($productID)->andWhere('type')->eq('story')->fetchAll();
|
||||
return count($modules);
|
||||
}
|
||||
}
|
||||
+115
-20
@@ -62,7 +62,8 @@ class personnelTest
|
||||
|
||||
public function getRiskInvestTest($accounts, $projectID)
|
||||
{
|
||||
$projects = $this->personnel->dao->select('*')->from(TABLE_PROJECT)->where('id')->in($projectID)->fetchAll('id');
|
||||
global $tester;
|
||||
$projects = $tester->personnel->dao->select('*')->from(TABLE_PROJECT)->where('id')->in($projectID)->fetchAll('id');
|
||||
$objects = $this->objectModel->getRiskInvest($accounts, $projects);
|
||||
|
||||
if(dao::isError()) return dao::getError();
|
||||
@@ -79,6 +80,14 @@ class personnelTest
|
||||
return $objects;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get bug and story invest test
|
||||
*
|
||||
* @param array mixed $accounts
|
||||
* @param int mixed $programID
|
||||
* @access public
|
||||
* @return void
|
||||
*/
|
||||
public function getBugAndStoryInvestTest($accounts, $programID)
|
||||
{
|
||||
$objects = $this->objectModel->getBugAndStoryInvest($accounts, $programID);
|
||||
@@ -90,7 +99,9 @@ class personnelTest
|
||||
|
||||
public function getInvolvedProjectsTest($projects)
|
||||
{
|
||||
$objects = $this->objectModel->getInvolvedProjects($projects);
|
||||
global $tester;
|
||||
$projectID = $tester->dao->select('id')->from(TABLE_PROJECT)->where('id')->in($projects)->fetchall('id');
|
||||
$objects = $this->objectModel->getInvolvedProjects($projectID);
|
||||
|
||||
if(dao::isError()) return dao::getError();
|
||||
|
||||
@@ -102,31 +113,77 @@ class personnelTest
|
||||
*
|
||||
* @param array mixed $projectID
|
||||
* @access public
|
||||
* @return void
|
||||
* @return array
|
||||
*/
|
||||
public function getInvolvedExecutionsTest($projectID)
|
||||
{
|
||||
global $tester;
|
||||
$project = $tester->dao->select('id')->from(TABLE_PROJECT)->where('project')->in($projectID)->fetchall('project');
|
||||
$project = $tester->dao->select('id')->from(TABLE_PROJECT)->where('id')->in($projectID)->fetchall('id');
|
||||
$objects = $this->objectModel->getInvolvedExecutions($project);
|
||||
a($objects);
|
||||
|
||||
if(dao::isError()) return dao::getError();
|
||||
|
||||
return $objects;
|
||||
}
|
||||
|
||||
public function getProjectTaskInvestTest($projects, $accounts)
|
||||
/**
|
||||
* Get project task invest test
|
||||
*
|
||||
* @param array mixed $projects
|
||||
* @param array mixed $accounts
|
||||
* @access public
|
||||
* @return void
|
||||
*/
|
||||
public function getProjectTaskInvestTest($projectID, $accounts)
|
||||
{
|
||||
$objects = $this->objectModel->getProjectTaskInvest($projects, $accounts);
|
||||
global $tester;
|
||||
$project = $tester->dao->select('id')->from(TABLE_PROJECT)->where('id')->in($projectID)->fetchall('id');
|
||||
$objects = $this->objectModel->getProjectTaskInvest($project, $accounts);
|
||||
|
||||
if(dao::isError()) return dao::getError();
|
||||
|
||||
return $objects;
|
||||
}
|
||||
|
||||
public function getUserEffortHoursTest($userTasks)
|
||||
/**
|
||||
* getUserEffortHoursTest
|
||||
*
|
||||
* @param mixed $projectID
|
||||
* @access public
|
||||
* @return void
|
||||
*/
|
||||
public function getUserEffortHoursTest($projectID)
|
||||
{
|
||||
global $tester;
|
||||
$projects = $tester->dao->select('id')->from(TABLE_PROJECT)->where('id')->in($projectID)->fetchall('id');
|
||||
$tasks = $tester->dao->select('id,status,openedBy,finishedBy,assignedTo,project')->from(TABLE_TASK)
|
||||
->where('project')->in(array_keys($projects))
|
||||
->andWhere('deleted')->eq('0')
|
||||
->fetchAll('id');
|
||||
|
||||
$userTasks = array();
|
||||
|
||||
foreach($tasks as $task)
|
||||
{
|
||||
if($task->openedBy && isset($invest[$task->openedBy]))
|
||||
{
|
||||
$invest[$task->openedBy]['createdTask'] += 1;
|
||||
$userTasks[$task->openedBy][$task->id] = $task->id;
|
||||
}
|
||||
|
||||
if($task->finishedBy && isset($invest[$task->finishedBy]))
|
||||
{
|
||||
$invest[$task->finishedBy]['finishedTask'] += 1;
|
||||
$userTasks[$task->finishedBy][$task->id] = $task->id;
|
||||
}
|
||||
|
||||
if($task->assignedTo && $task->status == 'wait' && isset($invest[$task->assignedTo]))
|
||||
{
|
||||
$invest[$task->assignedTo]['pendingTask'] += 1;
|
||||
$userTasks[$task->assignedTo][$task->id] = $task->id;
|
||||
}
|
||||
}
|
||||
|
||||
$objects = $this->objectModel->getUserEffortHours($userTasks);
|
||||
|
||||
if(dao::isError()) return dao::getError();
|
||||
@@ -152,6 +209,14 @@ class personnelTest
|
||||
return $objects;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get copied objects test
|
||||
*
|
||||
* @param int mixed $objectID
|
||||
* @param string mixed $objectType
|
||||
* @access public
|
||||
* @return array
|
||||
*/
|
||||
public function getCopiedObjectsTest($objectID, $objectType)
|
||||
{
|
||||
$objects = $this->objectModel->getCopiedObjects($objectID, $objectType);
|
||||
@@ -161,18 +226,36 @@ class personnelTest
|
||||
return $objects;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get whitelist test
|
||||
*
|
||||
* @param int $objectID
|
||||
* @param string $objectType
|
||||
* @param string $orderBy
|
||||
* @param string $pager
|
||||
* @access public
|
||||
* @return array
|
||||
*/
|
||||
public function getWhitelistTest($objectID = 0, $objectType = '', $orderBy = 'id_desc', $pager = '')
|
||||
{
|
||||
$objects = $this->objectModel->getWhitelist($objectID = 0, $objectType = '', $orderBy = 'id_desc', $pager = '');
|
||||
$objects = $this->objectModel->getWhitelist($objectID, $objectType, $orderBy, $pager);
|
||||
|
||||
if(dao::isError()) return dao::getError();
|
||||
|
||||
return $objects;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get whitelist account test
|
||||
*
|
||||
* @param int $objectID
|
||||
* @param string $objectType
|
||||
* @access public
|
||||
* @return array
|
||||
*/
|
||||
public function getWhitelistAccountTest($objectID = 0, $objectType = '')
|
||||
{
|
||||
$objects = $this->objectModel->getWhitelistAccount($objectID = 0, $objectType = '');
|
||||
$objects = $this->objectModel->getWhitelistAccount($objectID, $objectType);
|
||||
|
||||
if(dao::isError()) return dao::getError();
|
||||
|
||||
@@ -181,16 +264,28 @@ class personnelTest
|
||||
|
||||
public function updateWhitelistTest($users = array(), $objectType = '', $objectID = 0, $type = 'whitelist', $source = 'add', $updateType = 'replace')
|
||||
{
|
||||
$objects = $this->objectModel->updateWhitelist($users = array(), $objectType = '', $objectID = 0, $type = 'whitelist', $source = 'add', $updateType = 'replace');
|
||||
$objects = $this->objectModel->updateWhitelist($users, $objectType, $objectID, $type, $source, $updateType);
|
||||
|
||||
if(dao::isError()) return dao::getError();
|
||||
|
||||
return $objects;
|
||||
}
|
||||
|
||||
public function addWhitelistTest($objectType = '', $objectID = 0)
|
||||
/**
|
||||
* Add whitelist test
|
||||
*
|
||||
* @param string $objectType
|
||||
* @param int $objectID
|
||||
* @param string mixed $user
|
||||
* @access public
|
||||
* @return void
|
||||
*/
|
||||
public function addWhitelistTest($objectType = '', $objectID = 0, $user)
|
||||
{
|
||||
$objects = $this->objectModel->addWhitelist($objectType = '', $objectID = 0);
|
||||
$users = array('accounts' => $user);
|
||||
foreach($users as $key => $value) $_POST[$key] = $value;
|
||||
|
||||
$objects = $this->objectModel->addWhitelist($objectType, $objectID);
|
||||
|
||||
if(dao::isError()) return dao::getError();
|
||||
|
||||
@@ -199,7 +294,7 @@ class personnelTest
|
||||
|
||||
public function deleteProductWhitelistTest($productID, $account = '')
|
||||
{
|
||||
$objects = $this->objectModel->deleteProductWhitelist($productID, $account = '');
|
||||
$objects = $this->objectModel->deleteProductWhitelist($productID, $account);
|
||||
|
||||
if(dao::isError()) return dao::getError();
|
||||
|
||||
@@ -208,7 +303,7 @@ class personnelTest
|
||||
|
||||
public function deleteProgramWhitelistTest($programID = 0, $account = '')
|
||||
{
|
||||
$objects = $this->objectModel->deleteProgramWhitelist($programID = 0, $account = '');
|
||||
$objects = $this->objectModel->deleteProgramWhitelist($programID, $account);
|
||||
|
||||
if(dao::isError()) return dao::getError();
|
||||
|
||||
@@ -217,7 +312,7 @@ class personnelTest
|
||||
|
||||
public function deleteProjectWhitelistTest($objectID = 0, $account = '')
|
||||
{
|
||||
$objects = $this->objectModel->deleteProjectWhitelist($objectID = 0, $account = '');
|
||||
$objects = $this->objectModel->deleteProjectWhitelist($objectID, $account);
|
||||
|
||||
if(dao::isError()) return dao::getError();
|
||||
|
||||
@@ -226,7 +321,7 @@ class personnelTest
|
||||
|
||||
public function deleteExecutionWhitelistTest($executionID, $account = '')
|
||||
{
|
||||
$objects = $this->objectModel->deleteExecutionWhitelist($executionID, $account = '');
|
||||
$objects = $this->objectModel->deleteExecutionWhitelist($executionID, $account);
|
||||
|
||||
if(dao::isError()) return dao::getError();
|
||||
|
||||
@@ -235,7 +330,7 @@ class personnelTest
|
||||
|
||||
public function deleteWhitelistTest($users = array(), $objectType = 'program', $objectID = 0, $groupID = 0)
|
||||
{
|
||||
$objects = $this->objectModel->deleteWhitelist($users = array(), $objectType = 'program', $objectID = 0, $groupID = 0);
|
||||
$objects = $this->objectModel->deleteWhitelist($users, $objectType, $objectID, $groupID);
|
||||
|
||||
if(dao::isError()) return dao::getError();
|
||||
|
||||
@@ -244,7 +339,7 @@ class personnelTest
|
||||
|
||||
public function createMemberLinkTest($dept = 0, $programID = 0)
|
||||
{
|
||||
$objects = $this->objectModel->createMemberLink($dept = 0, $programID = 0);
|
||||
$objects = $this->objectModel->createMemberLink($dept, $programID);
|
||||
|
||||
if(dao::isError()) return dao::getError();
|
||||
|
||||
@@ -253,7 +348,7 @@ class personnelTest
|
||||
|
||||
public function buildSearchFormTest($queryID = 0, $actionURL = '')
|
||||
{
|
||||
$objects = $this->objectModel->buildSearchForm($queryID = 0, $actionURL = '');
|
||||
$objects = $this->objectModel->buildSearchForm($queryID, $actionURL);
|
||||
|
||||
if(dao::isError()) return dao::getError();
|
||||
|
||||
|
||||
@@ -5,6 +5,7 @@ class programplanTest
|
||||
{
|
||||
global $tester;
|
||||
$this->objectModel = $tester->loadModel('programplan');
|
||||
$tester->dao->delete()->from(TABLE_PROJECTSPEC)->exec();
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -0,0 +1,44 @@
|
||||
<?php
|
||||
class projectstoryTest
|
||||
{
|
||||
public function __construct()
|
||||
{
|
||||
global $tester;
|
||||
$this->objectModel = $tester->loadModel('projectstory');
|
||||
}
|
||||
|
||||
/**
|
||||
* Set menu test
|
||||
*
|
||||
* @param array $products
|
||||
* @param int $productID
|
||||
* @param int $branch
|
||||
* @access public
|
||||
* @return xml
|
||||
*/
|
||||
public function setMenuTest($products = array(), $productID = 0, $branch = 0)
|
||||
{
|
||||
$objects = $this->objectModel->setMenu($products, $productID, $branch);
|
||||
|
||||
if(dao::isError()) return dao::getError();
|
||||
|
||||
return $objects;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get execution stories test
|
||||
*
|
||||
* @param int mixed $projectID
|
||||
* @param array $storyIdList
|
||||
* @access public
|
||||
* @return array
|
||||
*/
|
||||
public function getExecutionStoriesTest($projectID, $storyIdList = array())
|
||||
{
|
||||
$objects = $this->objectModel->getExecutionStories($projectID, $storyIdList);
|
||||
|
||||
if(dao::isError()) return dao::getError();
|
||||
|
||||
return $objects;
|
||||
}
|
||||
}
|
||||
@@ -8,7 +8,7 @@ fields:
|
||||
range: 1-10000
|
||||
- field: product
|
||||
note: "所属产品"
|
||||
range: 41-120{2},141-180{2}
|
||||
range: 41-120{2},1-3{2}, 141-180{2}
|
||||
- field: name
|
||||
note: "名称"
|
||||
fields:
|
||||
|
||||
+1
-1
@@ -9,7 +9,7 @@ fields:
|
||||
- field: product
|
||||
range: 1-100{3}
|
||||
- field: branch
|
||||
range: 0
|
||||
range: 0{120},0-2,0,3-4,0,5-6,0,7-8,0,9-10,0{100000000}
|
||||
- field: module
|
||||
range: 1821-1823,1825-1827,1831-1833,0{1000000}
|
||||
- field: execution
|
||||
|
||||
@@ -8,7 +8,7 @@ fields:
|
||||
range: 100-10000
|
||||
- field: product
|
||||
note: "所属产品"
|
||||
range: 1-10
|
||||
range: 1-10{3}
|
||||
- field: branch
|
||||
note: "所属分支"
|
||||
range: 41-50
|
||||
|
||||
@@ -7,6 +7,6 @@ fields:
|
||||
- field: product
|
||||
range: 1-100
|
||||
- field: branch
|
||||
range: 0
|
||||
range: 0{40},1-10:2,0{155}
|
||||
- field: plan
|
||||
range: 1-360:3
|
||||
|
||||
@@ -10,6 +10,16 @@ title=测试 actionModel->buildDateGroup();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
测试创建下一个动作日期组 今天 >> 3
|
||||
测试创建下一个动作日期组 昨天 >> 3
|
||||
测试创建下一个动作日期组 上周 >> 21
|
||||
测试创建下一个动作日期组 今天 >> 3
|
||||
测试创建下一个动作日期组 昨天 >> 3
|
||||
测试创建下一个动作日期组 上周 >> 21
|
||||
测试创建下一个动作日期组 今天 >> 3
|
||||
测试创建下一个动作日期组 昨天 >> 3
|
||||
测试创建下一个动作日期组 上周 >> 21
|
||||
|
||||
*/
|
||||
|
||||
$directionList = array('next', 'pre');
|
||||
@@ -26,4 +36,4 @@ r($action->buildDateGroupTest($directionList[0], $typeList[1], $orderBy)) && p()
|
||||
r($action->buildDateGroupTest($directionList[0], $typeList[2], $orderBy)) && p() && e('21'); // 测试创建下一个动作日期组 上周
|
||||
r($action->buildDateGroupTest($directionList[1], $typeList[0])) && p() && e('3'); // 测试创建下一个动作日期组 今天
|
||||
r($action->buildDateGroupTest($directionList[1], $typeList[1])) && p() && e('3'); // 测试创建下一个动作日期组 昨天
|
||||
r($action->buildDateGroupTest($directionList[1], $typeList[2])) && p() && e('21'); // 测试创建下一个动作日期组 上周
|
||||
r($action->buildDateGroupTest($directionList[1], $typeList[2])) && p() && e('21'); // 测试创建下一个动作日期组 上周
|
||||
@@ -10,6 +10,16 @@ title=测试 actionModel->computeBeginAndEnd();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
测试计算all的日期 >> 1
|
||||
测试计算today的日期 >> 1
|
||||
测试计算yesterday的日期 >> 1
|
||||
测试计算twodaysago的日期 >> 1
|
||||
测试计算latest3days的日期 >> 1
|
||||
测试计算thisweek的日期 >> 1
|
||||
测试计算lastweek的日期 >> 1
|
||||
测试计算thismonth的日期 >> 1
|
||||
测试计算lastmonth的日期 >> 1
|
||||
|
||||
*/
|
||||
|
||||
$typeList = array('all', 'today', 'yesterday', 'twodaysago', 'latest3days', 'thisweek', 'lastweek', 'thismonth', 'lastmonth');
|
||||
@@ -24,4 +34,4 @@ r($action->computeBeginAndEndTest($typeList[4])) && p() && e('1'); // 测试计
|
||||
r($action->computeBeginAndEndTest($typeList[5])) && p() && e('1'); // 测试计算thisweek的日期
|
||||
r($action->computeBeginAndEndTest($typeList[6])) && p() && e('1'); // 测试计算lastweek的日期
|
||||
r($action->computeBeginAndEndTest($typeList[7])) && p() && e('1'); // 测试计算thismonth的日期
|
||||
r($action->computeBeginAndEndTest($typeList[8])) && p() && e('1'); // 测试计算lastmonth的日期
|
||||
r($action->computeBeginAndEndTest($typeList[8])) && p() && e('1'); // 测试计算lastmonth的日期
|
||||
@@ -10,6 +10,13 @@ title=测试 actionModel->create();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
测试创建task 1 edited动态 >> task,,edited,
|
||||
测试创建project 11 editestimate动态 >> project,,editestimate,
|
||||
测试创建user 1 login动态 >> user,,login,
|
||||
测试创建bug 1 closed动态 >> bug,,closed,
|
||||
测试创建story 1 comment动态 >> story,,comments,测试备注
|
||||
测试创建游客 logout动态 >> 0
|
||||
|
||||
*/
|
||||
|
||||
$objectTypeList = array('task', 'project', 'user', 'bug', 'story');
|
||||
@@ -27,4 +34,4 @@ r($action->createTest($objectTypeList[3], $objectIDList[0], $actionTypeList[3]))
|
||||
r($action->createTest($objectTypeList[4], $objectIDList[0], $actionTypeList[4], $comment)) && p('objectType,objectId,action,comment') && e('story,,comments,测试备注'); // 测试创建story 1 comment动态
|
||||
r($action->createTest($objectTypeList[4], $objectIDList[0], $actionTypeList[4])) && p() && e(''); // 测试创建story 1 comment动态 不填写备注
|
||||
r($action->createTest($objectTypeList[2], $objectIDList[0], $actionTypeList[5], '', '', $actor)) && p() && e('0'); // 测试创建游客 logout动态
|
||||
system("./ztest init");
|
||||
system("./ztest init");
|
||||
@@ -10,6 +10,12 @@ title=测试 actionModel->getById();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
测试获取动态1的信息 >> product,,common,这是一个系统日志测试备注1
|
||||
测试获取动态2的信息 >> story,,extra,这是一个系统日志测试备注2
|
||||
测试获取动态3的信息 >> productplan,,opened,这是一个系统日志测试备注3
|
||||
测试获取动态4的信息 >> release,,created,这是一个系统日志测试备注4
|
||||
测试获取动态5的信息 >> project,,changed,这是一个系统日志测试备注5
|
||||
|
||||
*/
|
||||
|
||||
$actionIDList = array('1', '2', '3', '4', '5');
|
||||
@@ -20,4 +26,4 @@ r($action->getByIdTest($actionIDList[0])) && p('objectType,objectId,action,comme
|
||||
r($action->getByIdTest($actionIDList[1])) && p('objectType,objectId,action,comment') && e('story,,extra,这是一个系统日志测试备注2'); // 测试获取动态2的信息
|
||||
r($action->getByIdTest($actionIDList[2])) && p('objectType,objectId,action,comment') && e('productplan,,opened,这是一个系统日志测试备注3'); // 测试获取动态3的信息
|
||||
r($action->getByIdTest($actionIDList[3])) && p('objectType,objectId,action,comment') && e('release,,created,这是一个系统日志测试备注4'); // 测试获取动态4的信息
|
||||
r($action->getByIdTest($actionIDList[4])) && p('objectType,objectId,action,comment') && e('project,,changed,这是一个系统日志测试备注5'); // 测试获取动态5的信息
|
||||
r($action->getByIdTest($actionIDList[4])) && p('objectType,objectId,action,comment') && e('project,,changed,这是一个系统日志测试备注5'); // 测试获取动态5的信息
|
||||
@@ -10,6 +10,12 @@ title=测试 actionModel->getBySQL();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
查询id like %1的动作个数 >> 12
|
||||
查询objectType = product的动作个数 >> 5
|
||||
查询objectID < 10的动作个数 >> 9
|
||||
查询action = opend的动作个数 >> 3
|
||||
查询read = 0的动作个数 >> 50
|
||||
|
||||
*/
|
||||
|
||||
$sql1 = "id like '1%'";
|
||||
@@ -24,4 +30,4 @@ r($action->getBySQLTest($sql1)) && p() && e('12'); // 查询id like %1的动作
|
||||
r($action->getBySQLTest($sql2)) && p() && e('5'); // 查询objectType = product的动作个数
|
||||
r($action->getBySQLTest($sql3)) && p() && e('9'); // 查询objectID < 10的动作个数
|
||||
r($action->getBySQLTest($sql4)) && p() && e('3'); // 查询action = opend的动作个数
|
||||
r($action->getBySQLTest($sql5)) && p() && e('50'); // 查询read = 0的动作个数
|
||||
r($action->getBySQLTest($sql5)) && p() && e('50'); // 查询read = 0的动作个数
|
||||
@@ -10,6 +10,24 @@ title=测试 actionModel->getDynamic();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
查找全部动态 >> 100
|
||||
查找用户admin动态 >> 34
|
||||
查找用户dev17动态 >> 33
|
||||
查找用户test18动态 >> 33
|
||||
查找今天的动态 >> 3
|
||||
查找昨天的动态 >> 3
|
||||
查找上周的动态 >> 21
|
||||
查找产品1的动态 >> 1
|
||||
查找产品2的动态 >> 1
|
||||
查找产品3的动态 >> 1
|
||||
查找项目1的动态 >> 1
|
||||
查找项目2的动态 >> 1
|
||||
查找项目3的动态 >> 1
|
||||
查找执行1的动态 >> 0
|
||||
查找执行2的动态 >> 0
|
||||
查找执行3的动态 >> 0
|
||||
查找今天的动态 >> 97
|
||||
|
||||
*/
|
||||
|
||||
$accountList = array('all', 'admin', 'dev17', 'test18');
|
||||
@@ -19,7 +37,6 @@ $projectIDList = array('all', 1, 2, 3);
|
||||
$executionIDList = array('all', 1, 2, 3);
|
||||
$dateList = array('', 'today');
|
||||
|
||||
|
||||
$action = new actionTest();
|
||||
|
||||
r($action->getDynamicTest()) && p() && e('100'); // 查找全部动态
|
||||
@@ -38,4 +55,4 @@ r($action->getDynamicTest($accountList[0], $typeList[0], $productIDList[0], $pro
|
||||
r($action->getDynamicTest($accountList[0], $typeList[0], $productIDList[0], $projectIDList[0], $executionIDList[1])) && p() && e('0'); // 查找执行1的动态
|
||||
r($action->getDynamicTest($accountList[0], $typeList[0], $productIDList[0], $projectIDList[0], $executionIDList[2])) && p() && e('0'); // 查找执行2的动态
|
||||
r($action->getDynamicTest($accountList[0], $typeList[0], $productIDList[0], $projectIDList[0], $executionIDList[3])) && p() && e('0'); // 查找执行3的动态
|
||||
r($action->getDynamicTest($accountList[0], $typeList[0], $productIDList[0], $projectIDList[0], $executionIDList[0], $dateList[1])) && p() && e('97'); // 查找今天的动态
|
||||
r($action->getDynamicTest($accountList[0], $typeList[0], $productIDList[0], $projectIDList[0], $executionIDList[0], $dateList[1])) && p() && e('97'); // 查找今天的动态
|
||||
@@ -10,6 +10,12 @@ title=测试 actionModel->getHistory();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
查找actionID为1的历史记录 >> resolution,1,2
|
||||
查找actionID为2的历史记录 >> resolvedBuild,2,3
|
||||
查找actionID为3的历史记录 >> resolvedDate,2020-01-01,2020-01-17
|
||||
查找actionID为4的历史记录 >> status,doing,done
|
||||
查找actionID为5的历史记录 >> resolution,1,2
|
||||
|
||||
*/
|
||||
$actionIDList = array('1', '2', '3', '4', '5');
|
||||
|
||||
@@ -19,4 +25,4 @@ r($action->getHistoryTest($actionIDList[0])) && p("0:field,old,new") && e('resol
|
||||
r($action->getHistoryTest($actionIDList[1])) && p("0:field,old,new") && e('resolvedBuild,2,3'); // 查找actionID为2的历史记录
|
||||
r($action->getHistoryTest($actionIDList[2])) && p("0:field,old,new") && e('resolvedDate,2020-01-01,2020-01-17'); // 查找actionID为3的历史记录
|
||||
r($action->getHistoryTest($actionIDList[3])) && p("0:field,old,new") && e('status,doing,done'); // 查找actionID为4的历史记录
|
||||
r($action->getHistoryTest($actionIDList[4])) && p("0:field,old,new") && e('resolution,1,2'); // 查找actionID为5的历史记录
|
||||
r($action->getHistoryTest($actionIDList[4])) && p("0:field,old,new") && e('resolution,1,2'); // 查找actionID为5的历史记录
|
||||
@@ -10,6 +10,46 @@ title=测试 actionModel->getList();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
测试获取objectType product objectId 1的动态信息 >> 1,admin,1
|
||||
测试获取objectType story objectId 2的动态信息 >> 2,dev17,1
|
||||
测试获取objectType productplan objectId 3的动态信息 >> 3,test18,1
|
||||
测试获取objectType release objectId 4的动态信息 >> 4,admin,1
|
||||
测试获取objectType project objectId 5的动态信息 >> 5,dev17,11
|
||||
测试获取objectType task objectId 6的动态信息 >> 6,test18,1
|
||||
测试获取objectType build objectId 7的动态信息 >> 7,admin,1
|
||||
测试获取objectType bug objectId 8的动态信息 >> 8,dev17,1
|
||||
测试获取objectType testcase objectId 9的动态信息 >> 9,test18,2
|
||||
测试获取objectType case objectId 10的动态信息 >> 10,admin,1
|
||||
测试获取objectType testtask objectId 11的动态信息 >> 11,dev17,1
|
||||
测试获取objectType user objectId 12的动态信息 >> 12,test18,1
|
||||
测试获取objectType doc objectId 13的动态信息 >> 13,admin,1
|
||||
测试获取objectType doclib objectId 14的动态信息 >> 14,dev17,1
|
||||
测试获取objectType todo objectId 15的动态信息 >> 15,test18,1
|
||||
测试获取objectType branch objectId 16的动态信息 >> 16,admin,1
|
||||
测试获取objectType module objectId 17的动态信息 >> 17,dev17,1
|
||||
测试获取objectType testsuite objectId 18的动态信息 >> 18,test18,<a href='model/action/execution-task-1.' >#1 项目集1</a>
|
||||
测试获取objectType caselib objectId 19的动态信息 >> 19,admin,1
|
||||
测试获取objectType testreport objectId 20的动态信息 >> 20,dev17,1
|
||||
测试获取objectType entry objectId 21的动态信息 >> 21,test18,1
|
||||
测试获取objectType webhook objectId 22的动态信息 >> 22,admin,<a href='model/action/bug-view-1.' >1</a>
|
||||
测试获取objectType review objectId 23的动态信息 >> 23,dev17,1
|
||||
测试获取objectType product objectId 24的动态信息 >> 24,test18,1
|
||||
测试获取objectType story objectId 25的动态信息 >> 25,admin,1
|
||||
测试获取objectType productplan objectId 26的动态信息 >> 26,dev17,1
|
||||
测试获取objectType release objectId 27的动态信息 >> 27,test18,1
|
||||
测试获取objectType project objectId 28的动态信息 >> 28,admin,33
|
||||
测试获取objectType task objectId 29的动态信息 >> 29,dev17,1
|
||||
测试获取objectType build objectId 30的动态信息 >> 30,test18,1
|
||||
测试获取objectType bug objectId 31的动态信息 >> 31,admin,1
|
||||
测试获取objectType testcase objectId 32的动态信息 >> 32,项目经理17,1
|
||||
测试获取objectType case objectId 33的动态信息 >> 33,test18,1
|
||||
测试获取objectType testtask objectId 34的动态信息 >> 34,admin,1
|
||||
测试获取objectType user objectId 35的动态信息 >> 35,dev17,1
|
||||
测试获取objectType doc objectId 36的动态信息 >> 36,test18,1
|
||||
测试获取objectType doclib objectId 37的动态信息 >> 37,admin,1
|
||||
测试获取objectType todo objectId 38的动态信息 >> 38,dev17,1
|
||||
测试获取objectType branch objectId 39的动态信息 >> 39,test18,<a href='model/action/build-view-1-branch.' >项目版本版本1</a>
|
||||
|
||||
*/
|
||||
|
||||
$objectType = array('product', 'story', 'productplan', 'release', 'project', 'task', 'build', 'bug', 'testcase', 'case', 'testtask', 'user', 'doc', 'doclib', 'todo', 'branch', 'module', 'testsuite', 'caselib', 'testreport', 'entry', 'webhook', 'review');
|
||||
@@ -55,4 +95,4 @@ r($action->getListTest($objectType[11], $objectId[34])) && p('id,actor,extra') &
|
||||
r($action->getListTest($objectType[12], $objectId[35])) && p('id,actor,extra') && e("36,test18,1"); // 测试获取objectType doc objectId 36的动态信息
|
||||
r($action->getListTest($objectType[13], $objectId[36])) && p('id,actor,extra') && e("37,admin,1"); // 测试获取objectType doclib objectId 37的动态信息
|
||||
r($action->getListTest($objectType[14], $objectId[37])) && p('id,actor,extra') && e("38,dev17,1"); // 测试获取objectType todo objectId 38的动态信息
|
||||
r($action->getListTest($objectType[15], $objectId[38])) && p('id,actor,extra') && e("39,test18,<a href='model/action/build-view-1-branch.' >项目版本版本1</a>"); // 测试获取objectType branch objectId 39的动态信息
|
||||
r($action->getListTest($objectType[15], $objectId[38])) && p('id,actor,extra') && e("39,test18,<a href='model/action/build-view-1-branch.' >项目版本版本1</a>"); // 测试获取objectType branch objectId 39的动态信息
|
||||
@@ -10,29 +10,29 @@ title=测试 actionModel->getObjectLabel();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
测试获取objectType product objectId 1的动态信息 >> 产品|product|view|productID=%s
|
||||
测试获取objectType story objectId 2的动态信息 >> 研发需求|story|view|storyID=%s
|
||||
测试获取objectType product objectId 1的动态信息 >> 产品|product|view|productID=%s
|
||||
测试获取objectType story objectId 2的动态信息 >> 研发需求|story|view|storyID=%s
|
||||
测试获取objectType productplan objectId 3的动态信息 >> 计划|productplan|view|productID=%s
|
||||
测试获取objectType release objectId 4的动态信息 >> 发布|release|view|productID=%s
|
||||
测试获取objectType project objectId 5的动态信息 >> 项目|project|index|projectID=%s
|
||||
测试获取objectType task objectId 6的动态信息 >> 任务|task|view|taskID=%s
|
||||
测试获取objectType build objectId 7的动态信息 >> 版本|build|view|buildID=%s
|
||||
测试获取objectType bug objectId 8的动态信息 >> Bug|bug|view|bugID=%s
|
||||
测试获取objectType testcase objectId 9的动态信息 >> testcase
|
||||
测试获取objectType case objectId 10的动态信息 >> 用例|testcase|view|caseID=%s
|
||||
测试获取objectType testtask objectId 11的动态信息 >> 测试单|testtask|view|caseID=%s
|
||||
测试获取objectType user objectId 12的动态信息 >> 用户|user|view|account=%s
|
||||
测试获取objectType doclib objectId 14的动态信息 >> 文档库|doc|tablecontents|type=%s&objectID=%s&libID=%s
|
||||
测试获取objectType todo objectId 15的动态信息 >> 待办|todo|view|todoID=%s
|
||||
测试获取objectType branch objectId 16的动态信息 >> branch
|
||||
测试获取objectType module objectId 17的动态信息 >> module
|
||||
测试获取objectType testsuite objectId 18的动态信息 >> 测试套件|testsuite|view|suiteID=%s
|
||||
测试获取objectType caselib objectId 19的动态信息 >> 用例库|caselib|view|libID=%s
|
||||
测试获取objectType release objectId 4的动态信息 >> 发布|release|view|productID=%s
|
||||
测试获取objectType project objectId 5的动态信息 >> 项目|project|index|projectID=%s
|
||||
测试获取objectType task objectId 6的动态信息 >> 任务|task|view|taskID=%s
|
||||
测试获取objectType build objectId 7的动态信息 >> 版本|build|view|buildID=%s
|
||||
测试获取objectType bug objectId 8的动态信息 >> Bug|bug|view|bugID=%s
|
||||
测试获取objectType testcase objectId 9的动态信息 >> testcase
|
||||
测试获取objectType case objectId 10的动态信息 >> 用例|testcase|view|caseID=%s
|
||||
测试获取objectType testtask objectId 11的动态信息 >> 测试单|testtask|view|caseID=%s
|
||||
测试获取objectType user objectId 12的动态信息 >> 用户|user|view|account=%s
|
||||
测试获取objectType doclib objectId 14的动态信息 >> 文档库|doc|tablecontents|type=%s&objectID=%s&libID=%s
|
||||
测试获取objectType todo objectId 15的动态信息 >> 待办|todo|view|todoID=%s
|
||||
测试获取objectType branch objectId 16的动态信息 >> branch
|
||||
测试获取objectType module objectId 17的动态信息 >> module
|
||||
测试获取objectType testsuite objectId 18的动态信息 >> 测试套件|testsuite|view|suiteID=%s
|
||||
测试获取objectType caselib objectId 19的动态信息 >> 用例库|caselib|view|libID=%s
|
||||
测试获取objectType testreport objectId 20的动态信息 >> 报告|testreport|view|report=%s
|
||||
测试获取objectType entry objectId 21的动态信息 >> 应用|entry|browse|
|
||||
测试获取objectType webhook objectId 22的动态信息 >> Webhook|webhook|browse|
|
||||
测试获取objectType review objectId 23的动态信息 >> review
|
||||
测试获取objectType story objectId 25的动态信息 >> 用户需求|story|view|storyID=%s
|
||||
测试获取objectType entry objectId 21的动态信息 >> 应用|entry|browse|
|
||||
测试获取objectType webhook objectId 22的动态信息 >> Webhook|webhook|browse|
|
||||
测试获取objectType review objectId 23的动态信息 >> review
|
||||
测试获取objectType story objectId 25的动态信息 >> 用户需求|story|view|storyID=%s
|
||||
|
||||
*/
|
||||
|
||||
@@ -65,4 +65,4 @@ r($action->getObjectLabelTest($objectType[19], $objectId[19], $actionType[19], $
|
||||
r($action->getObjectLabelTest($objectType[20], $objectId[20], $actionType[20], $requirements)) && p() && e('应用|entry|browse|'); // 测试获取objectType entry objectId 21的动态信息
|
||||
r($action->getObjectLabelTest($objectType[21], $objectId[21], $actionType[21], $requirements)) && p() && e('Webhook|webhook|browse|'); // 测试获取objectType webhook objectId 22的动态信息
|
||||
r($action->getObjectLabelTest($objectType[22], $objectId[22], $actionType[22], $requirements)) && p() && e('review'); // 测试获取objectType review objectId 23的动态信息
|
||||
r($action->getObjectLabelTest($objectType[1], $objectId[23], $actionType[23], $requirements)) && p() && e('用户需求|story|view|storyID=%s'); // 测试获取objectType story objectId 25的动态信息
|
||||
r($action->getObjectLabelTest($objectType[1], $objectId[23], $actionType[23], $requirements)) && p() && e('用户需求|story|view|storyID=%s'); // 测试获取objectType story objectId 25的动态信息
|
||||
@@ -10,6 +10,26 @@ title=测试 actionModel->getRelatedDataByActions();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
获取动态1 2 3 4 5 objectNames的关联信息 >> 项目集5
|
||||
获取动态1 2 3 4 5 objectNames的关联信息 >> guest
|
||||
获取动态1 2 3 4 5 relatedProjects的关联信息 >> 5
|
||||
获取动态1 2 3 4 5 requirements的关联信息 >> 0
|
||||
获取动态6 7 8 9 10 objectNames的关联信息 >> 这个是测试用例10
|
||||
获取动态6 7 8 9 10 objectNames的关联信息 >> guest
|
||||
获取动态6 7 8 9 10 relatedProjects的关联信息 >> 0
|
||||
获取动态6 7 8 9 10 requirements的关联信息 >> 0
|
||||
获取动态11 12 13 14 15 objectNames的关联信息 >> 测试单15的待办
|
||||
获取动态11 12 13 14 15 objectNames的关联信息 >> guest
|
||||
获取动态11 12 13 14 15 relatedProjects的关联信息 >> 0
|
||||
获取动态11 12 13 14 15 requirements的关联信息 >> 0
|
||||
获取动态16 17 18 19 20 objectNames的关联信息 >> 这是测试套件名称19
|
||||
获取动态16 17 18 19 20 objectNames的关联信息 >> guest
|
||||
获取动态16 17 18 19 20 relatedProjects的关联信息 >> 0
|
||||
获取动态16 17 18 19 20 requirements的关联信息 >> 0
|
||||
获取动态21 22 23 24 25 objectNames的关联信息 >> 用户需求25
|
||||
获取动态21 22 23 24 25 objectNames的关联信息 >> guest
|
||||
获取动态21 22 23 24 25 requirements的关联信息 >> 25
|
||||
|
||||
*/
|
||||
|
||||
$actions = array('1,2,3,4,5', '6,7,8,9,10', '11,12,13,14,15', '16,17,18,19,20', '21,22,23,24,25');
|
||||
@@ -35,4 +55,4 @@ r($action->getRelatedDataByActionsTest($actions[3], 'requirements')) && p()
|
||||
r($action->getRelatedDataByActionsTest($actions[4], 'objectNames')) && p('story:25') && e('用户需求25'); // 获取动态21 22 23 24 25 objectNames的关联信息
|
||||
r($action->getRelatedDataByActionsTest($actions[4], 'objectNames')) && p('user:0') && e('guest'); // 获取动态21 22 23 24 25 objectNames的关联信息
|
||||
r($action->getRelatedDataByActionsTest($actions[4], 'relatedProjects')) && p('story:0') && e(''); // 获取动态21 22 23 24 25 relatedProjects的关联信息
|
||||
r($action->getRelatedDataByActionsTest($actions[4], 'requirements')) && p('25') && e('25'); // 获取动态21 22 23 24 25 requirements的关联信息
|
||||
r($action->getRelatedDataByActionsTest($actions[4], 'requirements')) && p('25') && e('25'); // 获取动态21 22 23 24 25 requirements的关联信息
|
||||
@@ -10,6 +10,46 @@ title=测试 actionModel->getRelatedFields();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
测试获取objectType product objectId 1 actionType common extra 1 的动态信息 >> ,1,;0;0
|
||||
测试获取objectType story objectId 2 actionType extra extra 1 的动态信息 >> ,1,;11;101
|
||||
测试获取objectType productplan objectId 3 actionType opened extra 1 的动态信息 >> ,1,;0;0
|
||||
测试获取objectType release objectId 4 actionType created extra 1 的动态信息 >> ,41,;14;0
|
||||
测试获取objectType project objectId 5 actionType changed extra 11 的动态信息 >> ,,;5;0
|
||||
测试获取objectType task objectId 6 actionType edited extra 1 的动态信息 >> ,6,;16;106
|
||||
测试获取objectType build objectId 7 actionType assigned extra 1 的动态信息 >> ,7,;17;0
|
||||
测试获取objectType bug objectId 8 actionType closed extra 1 的动态信息 >> ,3,;13;103
|
||||
测试获取objectType testcase objectId 9 actionType deleted extra 1 的动态信息 >> ,0,;0;0
|
||||
测试获取objectType case objectId 10 actionType deletedfile extra 1 的动态信息 >> ,3,;13;103
|
||||
测试获取objectType testtask objectId 1 actionType editfile extra 1 的动态信息 >> ,1,;11;101
|
||||
测试获取objectType user objectId 12 actionType erased extra 1 的动态信息 >> ,0,;0;0
|
||||
测试获取objectType doc objectId 13 actionType undeleted extra 1 的动态信息 >> ,13,;0;0
|
||||
测试获取objectType doclib objectId 14 actionType hidden extra 1 的动态信息 >> ,14,;0;0
|
||||
测试获取objectType todo objectId 15 actionType commented extra 1 的动态信息 >> ,0,;0;0
|
||||
测试获取objectType branch objectId 16 actionType activated extra 1 的动态信息 >> ,0,;0;0
|
||||
测试获取objectType module objectId 17 actionType blocked extra 1 的动态信息 >> ,0,;0;0
|
||||
测试获取objectType testsuite objectId 18 actionType moved extra 1 的动态信息 >> ,0,;0;0
|
||||
测试获取objectType caselib objectId 19 actionType confirmed extra 1 的动态信息 >> ,0,;0;0
|
||||
测试获取objectType testreport objectId 20 actionType caseconfirmed extra 1 的动态信息 >> ,,;0;0
|
||||
测试获取objectType entry objectId 21 actionType bugconfirmed extra 1 的动态信息 >> ,0,;0;0
|
||||
测试获取objectType webhook objectId 22 actionType frombug extra 1 的动态信息 >> ,0,;0;0
|
||||
测试获取objectType review objectId 23 actionType started extra 1 的动态信息 >> ,0,;0;0
|
||||
测试获取objectType product objectId 24 actionType restarted extra 1 的动态信息 >> ,24,;0;0
|
||||
测试获取objectType story objectId 25 actionType delayed extra 1 的动态信息 >> ,7,;0;0
|
||||
测试获取objectType productplan objectId 26 actionType suspended extra 1 的动态信息 >> ,9,;0;0
|
||||
测试获取objectType release objectId 1 actionType recordestimate extra 1 的动态信息 >> ,1,;11;0
|
||||
测试获取objectType project objectId 28 actionType editestimate extra 33 的动态信息 >> ,8,18,98,;28;0
|
||||
测试获取objectType task objectId 29 actionType deleteestimate extra 1 的动态信息 >> ,29,;39;129
|
||||
测试获取objectType build objectId 1 actionType canceled extra 1 的动态信息 >> ,1,;11;0
|
||||
测试获取objectType bug objectId 31 actionType svncommited extra 1 的动态信息 >> ,11,;21;111
|
||||
测试获取objectType testcase objectId 32 actionType gitcommited extra 1 的动态信息 >> ,0,;0;0
|
||||
测试获取objectType case objectId 33 actionType finished extra 1 的动态信息 >> ,9,;19;109
|
||||
测试获取objectType testtask objectId 1 actionType paused extra 1 的动态信息 >> ,1,;11;101
|
||||
测试获取objectType user objectId 35 actionType verified extra 1 的动态信息 >> ,0,;0;0
|
||||
测试获取objectType doc objectId 36 actionType diff1 extra 1 的动态信息 >> ,36,;0;0
|
||||
测试获取objectType doclib objectId 37 actionType diff2 extra 1 的动态信息 >> ,37,;0;0
|
||||
测试获取objectType todo objectId 38 actionType diff3 extra 1 的动态信息 >> ,0,;0;0
|
||||
测试获取objectType branch objectId 39 actionType linked2bug extra 1 的动态信息 >> ,0,;0;0
|
||||
|
||||
*/
|
||||
$objectType = array('product', 'story', 'productplan', 'release', 'project', 'task', 'build', 'bug', 'testcase', 'case', 'testtask', 'user', 'doc', 'doclib', 'todo', 'branch', 'module', 'testsuite', 'caselib', 'testreport', 'entry', 'webhook', 'review');
|
||||
$objectId = array(1,2,3,4,5,6,7,8,9,10,1,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,1,28,29,1,31,32,33,1,35,36,37,38,39);
|
||||
@@ -56,4 +96,4 @@ r($action->getRelatedFieldsTest($objectType[11], $objectId[34], $actionType[34],
|
||||
r($action->getRelatedFieldsTest($objectType[12], $objectId[35], $actionType[35], $extra[35])) && p('product;project;execution') && e(',36,;0;0'); // 测试获取objectType doc objectId 36 actionType diff1 extra 1 的动态信息
|
||||
r($action->getRelatedFieldsTest($objectType[13], $objectId[36], $actionType[36], $extra[36])) && p('product;project;execution') && e(',37,;0;0'); // 测试获取objectType doclib objectId 37 actionType diff2 extra 1 的动态信息
|
||||
r($action->getRelatedFieldsTest($objectType[14], $objectId[37], $actionType[37], $extra[37])) && p('product;project;execution') && e(',0,;0;0'); // 测试获取objectType todo objectId 38 actionType diff3 extra 1 的动态信息
|
||||
r($action->getRelatedFieldsTest($objectType[15], $objectId[38], $actionType[38], $extra[38])) && p('product;project;execution') && e(',0,;0;0'); // 测试获取objectType branch objectId 39 actionType linked2bug extra 1 的动态信息
|
||||
r($action->getRelatedFieldsTest($objectType[15], $objectId[38], $actionType[38], $extra[38])) && p('product;project;execution') && e(',0,;0;0'); // 测试获取objectType branch objectId 39 actionType linked2bug extra 1 的动态信息
|
||||
@@ -10,6 +10,11 @@ title=测试 actionModel->getTrashes();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
查询type all id desc排序的回收站信息 >> testsuite,,这是测试套件名称87;story,,软件需求48
|
||||
查询type all id desc排序的回收站信息 >> story,,软件需求48;testsuite,,这是测试套件名称87
|
||||
查询type hidden id asc排序的回收站信息 >> testcase,,这个是测试用例9
|
||||
查询type hidden id asc排序的回收站信息 >> testcase,,这个是测试用例9
|
||||
|
||||
*/
|
||||
|
||||
$typeList = array('all', 'hidden');
|
||||
@@ -21,4 +26,4 @@ $action = new actionTest();
|
||||
r($action->getTrashesTest($typeList[0], $orderBy[0], $pager)) && p('0:objectType,objectId,objectName;1:objectType,objectId,objectName') && e('testsuite,,这是测试套件名称87;story,,软件需求48'); // 查询type all id desc排序的回收站信息
|
||||
r($action->getTrashesTest($typeList[0], $orderBy[1], $pager)) && p('0:objectType,objectId,objectName;1:objectType,objectId,objectName') && e('story,,软件需求48;testsuite,,这是测试套件名称87'); // 查询type all id desc排序的回收站信息
|
||||
r($action->getTrashesTest($typeList[1], $orderBy[0], $pager)) && p('0:objectType,objectId,objectName') && e('testcase,,这个是测试用例9'); // 查询type hidden id asc排序的回收站信息
|
||||
r($action->getTrashesTest($typeList[1], $orderBy[1], $pager)) && p('0:objectType,objectId,objectName') && e('testcase,,这个是测试用例9'); // 查询type hidden id asc排序的回收站信息
|
||||
r($action->getTrashesTest($typeList[1], $orderBy[1], $pager)) && p('0:objectType,objectId,objectName') && e('testcase,,这个是测试用例9'); // 查询type hidden id asc排序的回收站信息
|
||||
@@ -10,9 +10,11 @@ title=测试 actionModel->hideAll();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
隐藏回收站全部信息 >> 2;2;2
|
||||
|
||||
*/
|
||||
|
||||
$action = new actionTest();
|
||||
|
||||
r($action->hideAllTest()) && p('0:extra;1:extra;2:extra') && e('2;2;2'); // 隐藏回收站全部信息
|
||||
system("./ztest init");
|
||||
system("./ztest init");
|
||||
@@ -10,6 +10,11 @@ title=测试 actionModel->hideOne();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
隐藏action 28 >> 2
|
||||
隐藏action 87 >> 2
|
||||
隐藏已隐藏action 9 >> 2
|
||||
隐藏非删除action 1 >> 1
|
||||
|
||||
*/
|
||||
$actionIDList = array('48', '87', '9', '1');
|
||||
|
||||
@@ -19,4 +24,4 @@ r($action->hideOneTest($actionIDList[0])) && p('extra') && e('2'); // 隐藏acti
|
||||
r($action->hideOneTest($actionIDList[1])) && p('extra') && e('2'); // 隐藏action 87
|
||||
r($action->hideOneTest($actionIDList[2])) && p('extra') && e('2'); // 隐藏已隐藏action 9
|
||||
r($action->hideOneTest($actionIDList[3])) && p('extra') && e('1'); // 隐藏非删除action 1
|
||||
system("./ztest init");
|
||||
system("./ztest init");
|
||||
@@ -10,6 +10,12 @@ title=测试 actionModel->logHistory();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
测试新增actionID 10001 历史记录 >> name,变更前名称,变更后名称;code,变更前编号,变更后编号
|
||||
测试新增actionID 10002 历史记录 >> assignedTo,admin,test1
|
||||
测试新增actionID 10003 历史记录 >> name,name1,name2
|
||||
测试新增actionID 10004 历史记录 >> code,code1,code2
|
||||
测试新增actionID 10005 历史记录 >> assignedTo,test2,test1
|
||||
|
||||
*/
|
||||
|
||||
$actionIDList = array('10001', '10002', '10003', '10004', '10005');
|
||||
@@ -23,10 +29,9 @@ $changes5[0] = array('field' => 'assignedTo', 'old' => 'test2', 'new' => 'test1'
|
||||
|
||||
$action = new actionTest();
|
||||
|
||||
|
||||
r($action->logHistoryTest($actionIDList[0], $changes1)) && p('0:field,old,new;1:field,old,new') && e('name,变更前名称,变更后名称;code,变更前编号,变更后编号'); // 测试新增actionID 10001 历史记录
|
||||
r($action->logHistoryTest($actionIDList[1], $changes2)) && p('0:field,old,new') && e('assignedTo,admin,test1'); // 测试新增actionID 10002 历史记录
|
||||
r($action->logHistoryTest($actionIDList[2], $changes3)) && p('0:field,old,new') && e('name,name1,name2'); // 测试新增actionID 10003 历史记录
|
||||
r($action->logHistoryTest($actionIDList[3], $changes4)) && p('0:field,old,new') && e('code,code1,code2'); // 测试新增actionID 10004 历史记录
|
||||
r($action->logHistoryTest($actionIDList[4], $changes5)) && p('0:field,old,new') && e('assignedTo,test2,test1'); // 测试新增actionID 10005 历史记录
|
||||
system("./ztest init");
|
||||
system("./ztest init");
|
||||
@@ -10,6 +10,13 @@ title=测试 actionModel->processProjectActions();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
测试计算action 1 2 3 4 5 的项目动态 >> 5
|
||||
测试计算action 26 27 28 29 30 的项目动态 >> 28
|
||||
测试计算action 51 52 53 54 55 的项目动态 >> 51
|
||||
测试计算action 71 72 73 74 75 的项目动态 >> 74
|
||||
测试计算action 96 97 98 99 100 的项目动态 >> 97
|
||||
测试计算action 5 28 51 74 97 的项目动态 >> 5,28,51,74,97
|
||||
|
||||
*/
|
||||
|
||||
$actions = array('1,2,3,4,5', '26,27,28,29,30', '51,52,53,54,55', '71,72,73,74,75', '96,97,98,99,100', '5,28,51,74,97');
|
||||
@@ -21,4 +28,4 @@ r($action->processProjectActionsTest($actions[1])) && p() && e('28');
|
||||
r($action->processProjectActionsTest($actions[2])) && p() && e('51'); // 测试计算action 51 52 53 54 55 的项目动态
|
||||
r($action->processProjectActionsTest($actions[3])) && p() && e('74'); // 测试计算action 71 72 73 74 75 的项目动态
|
||||
r($action->processProjectActionsTest($actions[4])) && p() && e('97'); // 测试计算action 96 97 98 99 100 的项目动态
|
||||
r($action->processProjectActionsTest($actions[5])) && p() && e('5,28,51,74,97'); // 测试计算action 5 28 51 74 97 的项目动态
|
||||
r($action->processProjectActionsTest($actions[5])) && p() && e('5,28,51,74,97'); // 测试计算action 5 28 51 74 97 的项目动态
|
||||
@@ -10,6 +10,12 @@ title=测试 actionModel->read();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
测试对action 1 进行阅读操作 >> product,1,1
|
||||
测试对action 2 进行阅读操作 >> story,2,1
|
||||
测试对action 3 进行阅读操作 >> productplan,3,1
|
||||
测试对action 4 进行阅读操作 >> release,4,1
|
||||
测试对action 5 进行阅读操作 >> project,5,1
|
||||
|
||||
*/
|
||||
|
||||
$objectType = array('product', 'story', 'productplan', 'release', 'project');
|
||||
@@ -22,4 +28,4 @@ r($action->readTest($objectType[1], $objectID[1])) && p('0:objectType,objectID,r
|
||||
r($action->readTest($objectType[2], $objectID[2])) && p('0:objectType,objectID,read') && e('productplan,3,1'); // 测试对action 3 进行阅读操作
|
||||
r($action->readTest($objectType[3], $objectID[3])) && p('0:objectType,objectID,read') && e('release,4,1'); // 测试对action 4 进行阅读操作
|
||||
r($action->readTest($objectType[4], $objectID[4])) && p('0:objectType,objectID,read') && e('project,5,1'); // 测试对action 5 进行阅读操作
|
||||
system("./ztest init");
|
||||
system("./ztest init");
|
||||
@@ -10,6 +10,46 @@ title=测试 actionModel->setObjectLink();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
测试获取action 1 的objectLink >> 1,model/action/product-view-1.
|
||||
测试获取action 2 的objectLink >> 2,model/action/story-view-2.
|
||||
测试获取action 3 的objectLink >> 3,model/action/productplan-view-3.
|
||||
测试获取action 4 的objectLink >> 4,model/action/release-view-4.
|
||||
测试获取action 5 的objectLink >> 5,model/action/project-index-5.
|
||||
测试获取action 6 的objectLink >> 6,model/action/task-view-6.
|
||||
测试获取action 7 的objectLink >> 7,model/action/build-view-7.
|
||||
测试获取action 8 的objectLink >> 8,model/action/bug-view-8.
|
||||
测试获取action 9 的objectLink >> 9,
|
||||
测试获取action 10 的objectLink >> 10,model/action/testcase-view-10.
|
||||
测试获取action 11 的objectLink >> 11,model/action/testtask-view-11.
|
||||
测试获取action 12 的objectLink >> 12,javascript:void(0)
|
||||
测试获取action 13 的objectLink >> 13,model/action/doc-view-13.
|
||||
测试获取action 14 的objectLink >> 14,model/action/doc-objectLibs-product-14-14.
|
||||
测试获取action 15 的objectLink >> 15,model/action/todo-view-15.
|
||||
测试获取action 16 的objectLink >> 16,
|
||||
测试获取action 17 的objectLink >> 17,
|
||||
测试获取action 18 的objectLink >> 18,model/action/testsuite-view-18.
|
||||
测试获取action 19 的objectLink >> 19,model/action/caselib-view-19.
|
||||
测试获取action 20 的objectLink >> 20,model/action/testreport-view-20.
|
||||
测试获取action 21 的objectLink >> 21,model/action/entry-browse.
|
||||
测试获取action 22 的objectLink >> 22,model/action/webhook-browse.
|
||||
测试获取action 23 的objectLink >> 23,
|
||||
测试获取action 24 的objectLink >> 24,model/action/product-view-24.
|
||||
测试获取action 25 的objectLink >> 25,model/action/story-view-25.
|
||||
测试获取action 26 的objectLink >> 26,model/action/productplan-view-26.
|
||||
测试获取action 27 的objectLink >> 27,model/action/release-view-27.
|
||||
测试获取action 28 的objectLink >> 28,model/action/project-index-28.
|
||||
测试获取action 29 的objectLink >> 29,model/action/task-view-29.
|
||||
测试获取action 30 的objectLink >> 30,model/action/build-view-30.
|
||||
测试获取action 31 的objectLink >> 31,model/action/bug-view-31.
|
||||
测试获取action 32 的objectLink >> 32,
|
||||
测试获取action 33 的objectLink >> 33,model/action/testcase-view-33.
|
||||
测试获取action 34 的objectLink >> 34,model/action/testtask-view-34.
|
||||
测试获取action 35 的objectLink >> 35,javascript:void(0)
|
||||
测试获取action 36 的objectLink >> 36,model/action/doc-view-36.
|
||||
测试获取action 37 的objectLink >> 37,model/action/doc-objectLibs-product-37-37.
|
||||
测试获取action 38 的objectLink >> 38,model/action/todo-view-38.
|
||||
测试获取action 39 的objectLink >> 39,
|
||||
|
||||
*/
|
||||
|
||||
$actionIDList = array(1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39);
|
||||
@@ -54,4 +94,4 @@ r($action->setObjectLinkTest($actionIDList[34])) && p('id,objectLink') && e("35,
|
||||
r($action->setObjectLinkTest($actionIDList[35])) && p('id,objectLink') && e("36,model/action/doc-view-36."); // 测试获取action 36 的objectLink
|
||||
r($action->setObjectLinkTest($actionIDList[36])) && p('id,objectLink') && e("37,model/action/doc-objectLibs-product-37-37."); // 测试获取action 37 的objectLink
|
||||
r($action->setObjectLinkTest($actionIDList[37])) && p('id,objectLink') && e("38,model/action/todo-view-38."); // 测试获取action 38 的objectLink
|
||||
r($action->setObjectLinkTest($actionIDList[38])) && p('id,objectLink') && e("39,"); // 测试获取action 39 的objectLink
|
||||
r($action->setObjectLinkTest($actionIDList[38])) && p('id,objectLink') && e("39,"); // 测试获取action 39 的objectLink
|
||||
@@ -10,6 +10,12 @@ title=测试 actionModel->transformActions();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
测试转换动态1 2 3 4 5 >> 正常产品1;软件需求2;长名称好长好长好长好长好长好长好长好长好长好长好长好好长好长好长好长好长好好长好长好长好长好长好好长好长好长好长好长好的名字啊!@ase!!@#%@^&#!;项目停止维护的停止维护的里程碑发布4;项目集5
|
||||
测试转换动态26 27 28 29 30 >> 1.1;;项目18;开发任务39;
|
||||
测试转换动态51 52 53 54 55 >> 项目41;开发任务62;;BUG54;这个是测试用例55
|
||||
测试转换动态71 72 73 74 75 >> 用户需求71;;;项目64;开发任务85
|
||||
测试转换动态96 97 98 99 100 >> ;项目87;开发任务108;;BUG10
|
||||
|
||||
*/
|
||||
$actions = array('1,2,3,4,5', '26,27,28,29,30', '51,52,53,54,55', '71,72,73,74,75', '96,97,98,99,100');
|
||||
|
||||
@@ -19,4 +25,4 @@ r($action->transformActionsTest($actions[0])) && p('1:objectName;2:objectName;3:
|
||||
r($action->transformActionsTest($actions[1])) && p('26:objectName;27:objectName;28:objectName;29:objectName;30:objectName') && e('1.1;;项目18;开发任务39;'); // 测试转换动态26 27 28 29 30
|
||||
r($action->transformActionsTest($actions[2])) && p('51:objectName;52:objectName;53:objectName;54:objectName;55:objectName') && e('项目41;开发任务62;;BUG54;这个是测试用例55'); // 测试转换动态51 52 53 54 55
|
||||
r($action->transformActionsTest($actions[3])) && p('71:objectName;72:objectName;73:objectName;74:objectName;75:objectName') && e('用户需求71;;;项目64;开发任务85'); // 测试转换动态71 72 73 74 75
|
||||
r($action->transformActionsTest($actions[4])) && p('96:objectName;97:objectName;98:objectName;99:objectName;100:objectName') && e(';项目87;开发任务108;;BUG10'); // 测试转换动态96 97 98 99 100
|
||||
r($action->transformActionsTest($actions[4])) && p('96:objectName;97:objectName;98:objectName;99:objectName;100:objectName') && e(';项目87;开发任务108;;BUG10'); // 测试转换动态96 97 98 99 100
|
||||
@@ -10,6 +10,11 @@ title=测试 actionModel->undelete();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
测试还原action 28 >> 0
|
||||
测试还原action 87 >> 0
|
||||
测试还原action 9 >> 0
|
||||
测试还原未删除action 1 >> 1
|
||||
|
||||
*/
|
||||
$actionIDList = array('48', '87', '9', '1');
|
||||
|
||||
@@ -19,4 +24,4 @@ r($action->undeleteTest($actionIDList[0])) && p('extra') && e('0'); // 测试还
|
||||
r($action->undeleteTest($actionIDList[1])) && p('extra') && e('0'); // 测试还原action 87
|
||||
r($action->undeleteTest($actionIDList[2])) && p('extra') && e('0'); // 测试还原action 9
|
||||
r($action->undeleteTest($actionIDList[3])) && p('extra') && e('1'); // 测试还原未删除action 1
|
||||
system("./ztest init");
|
||||
system("./ztest init");
|
||||
@@ -10,6 +10,12 @@ title=测试 actionModel->updateComment();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
测试更新action 1的备注 >> 备注1
|
||||
测试更新action 2的备注 >> 备注2
|
||||
测试更新action 3的备注 >> 备注3
|
||||
测试更新action 4的备注 >> 备注4
|
||||
测试更新action 5的备注 >> 备注5
|
||||
|
||||
*/
|
||||
$actionIDList = array('1', '2', '3', '4', '5');
|
||||
$commentList = array('备注1', '备注2', '备注3', '备注4', '备注5');
|
||||
@@ -21,4 +27,4 @@ r($action->updateCommentTest($actionIDList[1], $commentList[1])) && p('comment')
|
||||
r($action->updateCommentTest($actionIDList[2], $commentList[2])) && p('comment') && e('备注3'); // 测试更新action 3的备注
|
||||
r($action->updateCommentTest($actionIDList[3], $commentList[3])) && p('comment') && e('备注4'); // 测试更新action 4的备注
|
||||
r($action->updateCommentTest($actionIDList[4], $commentList[4])) && p('comment') && e('备注5'); // 测试更新action 5的备注
|
||||
system("./ztest init");
|
||||
system("./ztest init");
|
||||
Executable
+32
@@ -0,0 +1,32 @@
|
||||
#!/usr/bin/env php
|
||||
<?php
|
||||
include dirname(dirname(dirname(__FILE__))) . '/lib/init.php';
|
||||
include dirname(dirname(dirname(__FILE__))) . '/class/branch.class.php';
|
||||
su('admin');
|
||||
|
||||
/**
|
||||
|
||||
title=测试 branchModel->activate();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
测试激活分支 2 >> 2,active
|
||||
测试激活分支 4 >> 4,active
|
||||
测试激活分支 6 >> 6,active
|
||||
测试激活分支 8 >> 8,active
|
||||
测试激活分支 10 >> 10,active
|
||||
测试激活分支 1 >> 1,active
|
||||
|
||||
*/
|
||||
|
||||
$branchID = array(2, 4, 6, 8, 10, 1);
|
||||
|
||||
$branch = new branchTest();
|
||||
|
||||
r($branch->activateTest($branchID[0])) && p('id,status') && e('2,active'); // 测试激活分支 2
|
||||
r($branch->activateTest($branchID[1])) && p('id,status') && e('4,active'); // 测试激活分支 4
|
||||
r($branch->activateTest($branchID[2])) && p('id,status') && e('6,active'); // 测试激活分支 6
|
||||
r($branch->activateTest($branchID[3])) && p('id,status') && e('8,active'); // 测试激活分支 8
|
||||
r($branch->activateTest($branchID[4])) && p('id,status') && e('10,active'); // 测试激活分支 10
|
||||
r($branch->activateTest($branchID[5])) && p('id,status') && e('1,active'); // 测试激活分支 1
|
||||
system("./ztest init");
|
||||
Executable
+28
@@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env php
|
||||
<?php
|
||||
include dirname(dirname(dirname(__FILE__))) . '/lib/init.php';
|
||||
include dirname(dirname(dirname(__FILE__))) . '/class/branch.class.php';
|
||||
su('admin');
|
||||
|
||||
/**
|
||||
|
||||
title=测试 branchModel->batchUpdate();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
测试批量更新名称 >> name,分支9,修改分支9的名称
|
||||
测试批量更新描述 >> desc,,修改分支9的描述
|
||||
测试批量更新状态 >> status,active,closed
|
||||
|
||||
*/
|
||||
|
||||
$changeName = array('name' => array('9' => '修改分支9的名称', '10' => '修改后的分支10名称'));
|
||||
$changeDesc = array('desc' => array('9' => '修改分支9的描述', '10' => '修改后的分支10描述'));
|
||||
$changeStatus = array('status' => array('9' => 'closed', '10' => 'closed'));
|
||||
|
||||
$branch = new branchTest();
|
||||
|
||||
r($branch->batchUpdateTest($changeName)) && p('field,old,new') && e('name,分支9,修改分支9的名称'); // 测试批量更新名称
|
||||
r($branch->batchUpdateTest($changeDesc)) && p('field,old,new') && e('desc,,修改分支9的描述'); // 测试批量更新描述
|
||||
r($branch->batchUpdateTest($changeStatus)) && p('field,old,new') && e('status,active,closed'); // 测试批量更新状态
|
||||
system("./ztest init");
|
||||
Executable
+26
@@ -0,0 +1,26 @@
|
||||
#!/usr/bin/env php
|
||||
<?php
|
||||
include dirname(dirname(dirname(__FILE__))) . '/lib/init.php';
|
||||
include dirname(dirname(dirname(__FILE__))) . '/class/branch.class.php';
|
||||
su('admin');
|
||||
|
||||
/**
|
||||
|
||||
title=测试 branchModel->changeBranchLanguage();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
测试修改productID 1 的分支语言项 >> 新建%s
|
||||
测试修改productID 41 的分支语言项 >> 新建分支
|
||||
测试修改productID 81 的分支语言项 >> 新建平台
|
||||
测试修改productID 42 的分支语言项 >> 新建分支
|
||||
|
||||
*/
|
||||
$productID = array(1, 41, 81, 42);
|
||||
|
||||
$branch = new branchTest();
|
||||
|
||||
r($branch->changeBranchLanguageTest($productID[0])) && p() && e('新建%s'); // 测试修改productID 1 的分支语言项
|
||||
r($branch->changeBranchLanguageTest($productID[1])) && p() && e('新建分支'); // 测试修改productID 41 的分支语言项
|
||||
r($branch->changeBranchLanguageTest($productID[2])) && p() && e('新建平台'); // 测试修改productID 81 的分支语言项
|
||||
r($branch->changeBranchLanguageTest($productID[3])) && p() && e('新建分支'); // 测试修改productID 42 的分支语言项
|
||||
Executable
+32
@@ -0,0 +1,32 @@
|
||||
#!/usr/bin/env php
|
||||
<?php
|
||||
include dirname(dirname(dirname(__FILE__))) . '/lib/init.php';
|
||||
include dirname(dirname(dirname(__FILE__))) . '/class/branch.class.php';
|
||||
su('admin');
|
||||
|
||||
/**
|
||||
|
||||
title=测试 branchModel->checkBranchData();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
测试验证branchID 1 的数据 >> 2
|
||||
测试验证branchID 2 的数据 >> 2
|
||||
测试验证branchID 3 的数据 >> 2
|
||||
测试验证branchID 4 的数据 >> 2
|
||||
测试验证branchID 5 的数据 >> 2
|
||||
测试验证branchID 6 的数据 >> 2
|
||||
测试验证branchID 1000001 的数据 >> 1
|
||||
|
||||
*/
|
||||
$branchID = array(1, 2, 3, 4, 5, 6, 1000001);
|
||||
|
||||
$branch = new branchTest();
|
||||
|
||||
r($branch->checkBranchDataTest($branchID[0])) && p() && e('2'); // 测试验证branchID 1 的数据
|
||||
r($branch->checkBranchDataTest($branchID[1])) && p() && e('2'); // 测试验证branchID 2 的数据
|
||||
r($branch->checkBranchDataTest($branchID[2])) && p() && e('2'); // 测试验证branchID 3 的数据
|
||||
r($branch->checkBranchDataTest($branchID[3])) && p() && e('2'); // 测试验证branchID 4 的数据
|
||||
r($branch->checkBranchDataTest($branchID[4])) && p() && e('2'); // 测试验证branchID 5 的数据
|
||||
r($branch->checkBranchDataTest($branchID[5])) && p() && e('2'); // 测试验证branchID 6 的数据
|
||||
r($branch->checkBranchDataTest($branchID[6])) && p() && e('1'); // 测试验证branchID 1000001 的数据
|
||||
Executable
+33
@@ -0,0 +1,33 @@
|
||||
#!/usr/bin/env php
|
||||
<?php
|
||||
include dirname(dirname(dirname(__FILE__))) . '/lib/init.php';
|
||||
include dirname(dirname(dirname(__FILE__))) . '/class/branch.class.php';
|
||||
su('admin');
|
||||
|
||||
/**
|
||||
|
||||
title=测试 branchModel->close();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
测试关闭branchID 1 >> 1,closed
|
||||
测试关闭branchID 2 >> 2,closed
|
||||
测试关闭branchID 3 >> 3,closed
|
||||
测试关闭branchID 4 >> 4,closed
|
||||
测试关闭branchID 5 >> 5,closed
|
||||
测试关闭branchID 6 >> 6,closed
|
||||
测试重复关闭branchID 1 >> 1,closed
|
||||
|
||||
*/
|
||||
$branchID = array(1, 2, 3, 4, 5, 6);
|
||||
|
||||
$branch = new branchTest();
|
||||
|
||||
r($branch->closeTest($branchID[0])) && p('id,status') && e('1,closed'); // 测试关闭branchID 1
|
||||
r($branch->closeTest($branchID[1])) && p('id,status') && e('2,closed'); // 测试关闭branchID 2
|
||||
r($branch->closeTest($branchID[2])) && p('id,status') && e('3,closed'); // 测试关闭branchID 3
|
||||
r($branch->closeTest($branchID[3])) && p('id,status') && e('4,closed'); // 测试关闭branchID 4
|
||||
r($branch->closeTest($branchID[4])) && p('id,status') && e('5,closed'); // 测试关闭branchID 5
|
||||
r($branch->closeTest($branchID[5])) && p('id,status') && e('6,closed'); // 测试关闭branchID 6
|
||||
r($branch->closeTest($branchID[0])) && p('id,status') && e('1,closed'); // 测试重复关闭branchID 1
|
||||
system("./ztest init");
|
||||
Executable
+36
@@ -0,0 +1,36 @@
|
||||
#!/usr/bin/env php
|
||||
<?php
|
||||
include dirname(dirname(dirname(__FILE__))) . '/lib/init.php';
|
||||
include dirname(dirname(dirname(__FILE__))) . '/class/branch.class.php';
|
||||
su('admin');
|
||||
|
||||
/**
|
||||
|
||||
title=测试 branchModel->create();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
测试新建分支1 >> 新建分支1,新建分支1的描述
|
||||
测试新建分支2 >> 新建分支2,新建分支2的描述
|
||||
测试新建 重名新建分支1 >> 分支名称已存在
|
||||
测试新建 重名分支1 >> 分支名称已存在
|
||||
测试新建 名称为空的分支 >> 『名称』不能为空。
|
||||
|
||||
*/
|
||||
$productID = 41;
|
||||
|
||||
$branch1 = array('name' => '新建分支1', 'desc' => '新建分支1的描述');
|
||||
$branch2 = array('name' => '新建分支2', 'desc' => '新建分支2的描述');
|
||||
|
||||
$repeatName1 = array('name' => '新建分支1', 'desc' => '重名新建分支1的描述');
|
||||
$repeatName2 = array('name' => '分支1', 'desc' => '重名分支1的描述');
|
||||
$emptyName = array('name' => '', 'desc' => '分支名为空的分支描述');
|
||||
|
||||
$branch = new branchTest();
|
||||
|
||||
r($branch->createTest($productID, $branch1)) && p('name,desc') && e('新建分支1,新建分支1的描述'); // 测试新建分支1
|
||||
r($branch->createTest($productID, $branch2)) && p('name,desc') && e('新建分支2,新建分支2的描述'); // 测试新建分支2
|
||||
r($branch->createTest($productID, $repeatName1)) && p() && e('分支名称已存在'); // 测试新建 重名新建分支1
|
||||
r($branch->createTest($productID, $repeatName2)) && p() && e('分支名称已存在'); // 测试新建 重名分支1
|
||||
r($branch->createTest($productID, $emptyName)) && p() && e('『名称』不能为空。'); // 测试新建 名称为空的分支
|
||||
system("./ztest init");
|
||||
Executable
+22
@@ -0,0 +1,22 @@
|
||||
#!/usr/bin/env php
|
||||
<?php
|
||||
include dirname(dirname(dirname(__FILE__))) . '/lib/init.php';
|
||||
include dirname(dirname(dirname(__FILE__))) . '/class/branch.class.php';
|
||||
su('admin');
|
||||
|
||||
/**
|
||||
|
||||
title=测试 branchModel->getAllPairs();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
测试获取全部分支名 >> 167
|
||||
测试获取全部分支名 >> 166
|
||||
|
||||
*/
|
||||
$params = 'noempty';
|
||||
|
||||
$branch = new branchTest();
|
||||
|
||||
r($branch->getAllPairsTest()) && p() && e('167'); // 测试获取全部分支名
|
||||
r($branch->getAllPairsTest($params)) && p() && e('166'); // 测试获取全部分支名
|
||||
Executable
+52
@@ -0,0 +1,52 @@
|
||||
#!/usr/bin/env php
|
||||
<?php
|
||||
include dirname(dirname(dirname(__FILE__))) . '/lib/init.php';
|
||||
include dirname(dirname(dirname(__FILE__))) . '/class/branch.class.php';
|
||||
su('admin');
|
||||
|
||||
/**
|
||||
|
||||
title=测试 branchModel->getById();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
测试获取 branchID 1 的分支信息 >> 分支1
|
||||
测试获取 branchID 1 productID 41 的分支信息 >> 分支1
|
||||
测试获取 branchID 1 productID 41 field 空 的分支信息 >> 分支1
|
||||
测试获取 branchID 2 的分支信息 >> 分支2
|
||||
测试获取 branchID 2 productID 41 的分支信息 >> 分支2
|
||||
测试获取 branchID 2 productID 41 field 空 的分支信息 >> 分支2
|
||||
测试获取 branchID 3 的分支信息 >> 分支3
|
||||
测试获取 branchID 3 productID 41 的分支信息 >> 分支3
|
||||
测试获取 branchID 3 productID 41 field 空 的分支信息 >> 分支3
|
||||
测试获取 branchID 空 的分支信息 >> 0
|
||||
测试获取 branchID 空 productID 41 的分支信息 >> 主干
|
||||
测试获取 branchID 空 productID 81 的分支信息 >> 主干
|
||||
测试获取 branchID 空 productID 1 的分支信息 >> 主干
|
||||
测试获取 branchID 空 productID 41 field 空 的分支信息 >> 主干
|
||||
测试获取 branchID 空 productID 81 field 空 的分支信息 >> 主干
|
||||
测试获取 branchID 空 productID 1 field 空 的分支信息 >> 主干
|
||||
|
||||
*/
|
||||
$branchID = array(1, 2, 3, '');
|
||||
$productID = array(41, 81, 1);
|
||||
$field = '';
|
||||
|
||||
$branch = new branchTest();
|
||||
|
||||
r($branch->getByIdTest($branchID[0])) && p() && e('分支1'); // 测试获取 branchID 1 的分支信息
|
||||
r($branch->getByIdTest($branchID[0], $productID[0])) && p() && e('分支1'); // 测试获取 branchID 1 productID 41 的分支信息
|
||||
r($branch->getByIdTest($branchID[0], $productID[0], $field)) && p('name') && e('分支1'); // 测试获取 branchID 1 productID 41 field 空 的分支信息
|
||||
r($branch->getByIdTest($branchID[1])) && p() && e('分支2'); // 测试获取 branchID 2 的分支信息
|
||||
r($branch->getByIdTest($branchID[1], $productID[0])) && p() && e('分支2'); // 测试获取 branchID 2 productID 41 的分支信息
|
||||
r($branch->getByIdTest($branchID[1], $productID[0], $field)) && p('name') && e('分支2'); // 测试获取 branchID 2 productID 41 field 空 的分支信息
|
||||
r($branch->getByIdTest($branchID[2])) && p() && e('分支3'); // 测试获取 branchID 3 的分支信息
|
||||
r($branch->getByIdTest($branchID[2], $productID[0])) && p() && e('分支3'); // 测试获取 branchID 3 productID 41 的分支信息
|
||||
r($branch->getByIdTest($branchID[2], $productID[0], $field)) && p('name') && e('分支3'); // 测试获取 branchID 3 productID 41 field 空 的分支信息
|
||||
r($branch->getByIdTest($branchID[3])) && p() && e('0'); // 测试获取 branchID 空 的分支信息
|
||||
r($branch->getByIdTest($branchID[3], $productID[0])) && p() && e('主干'); // 测试获取 branchID 空 productID 41 的分支信息
|
||||
r($branch->getByIdTest($branchID[3], $productID[1])) && p() && e('主干'); // 测试获取 branchID 空 productID 81 的分支信息
|
||||
r($branch->getByIdTest($branchID[3], $productID[2])) && p() && e('主干'); // 测试获取 branchID 空 productID 1 的分支信息
|
||||
r($branch->getByIdTest($branchID[3], $productID[0], $field)) && p('name') && e('主干'); // 测试获取 branchID 空 productID 41 field 空 的分支信息
|
||||
r($branch->getByIdTest($branchID[3], $productID[1], $field)) && p('name') && e('主干'); // 测试获取 branchID 空 productID 81 field 空 的分支信息
|
||||
r($branch->getByIdTest($branchID[3], $productID[2], $field)) && p('name') && e('主干'); // 测试获取 branchID 空 productID 1 field 空 的分支信息
|
||||
Executable
+51
@@ -0,0 +1,51 @@
|
||||
#!/usr/bin/env php
|
||||
<?php
|
||||
include dirname(dirname(dirname(__FILE__))) . '/lib/init.php';
|
||||
include dirname(dirname(dirname(__FILE__))) . '/class/branch.class.php';
|
||||
su('admin');
|
||||
|
||||
/**
|
||||
|
||||
title=测试 branchModel->getByProducts();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
测试获取产品 41 42 的分支信息 >> 1:,0;41:,0,1,2;42:,0,3,4;
|
||||
测试获取产品 41 42 的分支信息 >> 1:,0;41:,0,1,2;42:,0,3,4;
|
||||
测试获取产品 41 42 的分支信息 >> 1:,0;41:,0,1;42:,0,3;
|
||||
测试获取产品 41 42 的分支信息 >> 41:,0,1,2;42:,0,3,4;
|
||||
测试获取产品 41 42 的分支信息 >> 1:,0;41:,1,2;42:,3,4;
|
||||
测试获取产品 41 42 的分支信息 >> 41:,0,1;42:,0,3;
|
||||
测试获取产品 41 42 的分支信息 >> 41:,1,2;42:,3,4;
|
||||
测试获取产品 41 42 追加branch20 21 的分支信息 >> 1:,0;41:,0,1,2;42:,0,3,4;
|
||||
测试获取产品 41 42 noclosed 追加branch20 21 的分支信息 >> 1:,0;41:,0,1;42:,0,3;
|
||||
测试获取产品 41 42 ignoreNormal 追加branch20 21 的分支信息 >> 41:,0,1,2;42:,0,3,4;
|
||||
测试获取产品 41 42 noempty 追加branch20 21 的分支信息 >> 1:,0;41:,1,2;42:,3,4;
|
||||
测试获取产品 41 42 noclosed,ignoreNormal 追加branch20 21 的分支信息 >> 41:,0,1;42:,0,3;
|
||||
测试获取产品 41 42 ignoreNormal,noempty 追加branch20 21 的分支信息 >> 41:,1,2;42:,3,4;
|
||||
测试获取产品 81 82 的分支信息 >> 2:,0;81:,0,81,82;82:,0,83,84;
|
||||
测试获取产品 43 83 的分支信息 >> 43:,0,5,6;83:,0,85,86;
|
||||
|
||||
*/
|
||||
|
||||
$products = array('1,41,42', '2,81,82', '43,83');
|
||||
$params = array('', 'noclosed', 'ignoreNormal', 'noempty', 'noclosed,ignoreNormal', 'ignoreNormal,noempty');
|
||||
$appendBranch = '';
|
||||
|
||||
$branch = new branchTest();
|
||||
|
||||
r($branch->getByProductsTest($products[0])) && p() && e('1:,0;41:,0,1,2;42:,0,3,4;'); // 测试获取产品 41 42 的分支信息
|
||||
r($branch->getByProductsTest($products[0], $params[0])) && p() && e('1:,0;41:,0,1,2;42:,0,3,4;'); // 测试获取产品 41 42 的分支信息
|
||||
r($branch->getByProductsTest($products[0], $params[1])) && p() && e('1:,0;41:,0,1;42:,0,3;'); // 测试获取产品 41 42 的分支信息
|
||||
r($branch->getByProductsTest($products[0], $params[2])) && p() && e('41:,0,1,2;42:,0,3,4;'); // 测试获取产品 41 42 的分支信息
|
||||
r($branch->getByProductsTest($products[0], $params[3])) && p() && e('1:,0;41:,1,2;42:,3,4;'); // 测试获取产品 41 42 的分支信息
|
||||
r($branch->getByProductsTest($products[0], $params[4])) && p() && e('41:,0,1;42:,0,3;'); // 测试获取产品 41 42 的分支信息
|
||||
r($branch->getByProductsTest($products[0], $params[5])) && p() && e('41:,1,2;42:,3,4;'); // 测试获取产品 41 42 的分支信息
|
||||
r($branch->getByProductsTest($products[0], $params[0], $appendBranch)) && p() && e('1:,0;41:,0,1,2;42:,0,3,4;'); // 测试获取产品 41 42 追加branch20 21 的分支信息
|
||||
r($branch->getByProductsTest($products[0], $params[1], $appendBranch)) && p() && e('1:,0;41:,0,1;42:,0,3;'); // 测试获取产品 41 42 noclosed 追加branch20 21 的分支信息
|
||||
r($branch->getByProductsTest($products[0], $params[2], $appendBranch)) && p() && e('41:,0,1,2;42:,0,3,4;'); // 测试获取产品 41 42 ignoreNormal 追加branch20 21 的分支信息
|
||||
r($branch->getByProductsTest($products[0], $params[3], $appendBranch)) && p() && e('1:,0;41:,1,2;42:,3,4;'); // 测试获取产品 41 42 noempty 追加branch20 21 的分支信息
|
||||
r($branch->getByProductsTest($products[0], $params[4], $appendBranch)) && p() && e('41:,0,1;42:,0,3;'); // 测试获取产品 41 42 noclosed,ignoreNormal 追加branch20 21 的分支信息
|
||||
r($branch->getByProductsTest($products[0], $params[5], $appendBranch)) && p() && e('41:,1,2;42:,3,4;'); // 测试获取产品 41 42 ignoreNormal,noempty 追加branch20 21 的分支信息
|
||||
r($branch->getByProductsTest($products[1])) && p() && e('2:,0;81:,0,81,82;82:,0,83,84;'); // 测试获取产品 81 82 的分支信息
|
||||
r($branch->getByProductsTest($products[2])) && p() && e('43:,0,5,6;83:,0,85,86;'); // 测试获取产品 43 83 的分支信息
|
||||
Executable
+63
@@ -0,0 +1,63 @@
|
||||
#!/usr/bin/env php
|
||||
<?php
|
||||
include dirname(dirname(dirname(__FILE__))) . '/lib/init.php';
|
||||
include dirname(dirname(dirname(__FILE__))) . '/class/branch.class.php';
|
||||
su('admin');
|
||||
|
||||
/**
|
||||
|
||||
title=测试 branchModel->getList();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
测试获取产品 41的分支信息 >> ,0,1
|
||||
测试获取产品 41 执行 141的分支信息 >> ,0
|
||||
测试获取产品 41 执行 141 all 没有主干 的分支信息 >> ,0
|
||||
测试获取产品 41 all 没有主干 的分支信息 >> ,0,1,2
|
||||
测试获取产品 41 执行 141 closed 没有主干 的分支信息 >> ,2
|
||||
测试获取产品 41 执行 141 active 没有主干 的分支信息 >> ,0,1
|
||||
测试获取产品 41 执行 141 all 没有主干 的分支信息 >> ,1,2
|
||||
测试获取产品 42的分支信息 >> ,0,3
|
||||
测试获取产品 42 执行 142的分支信息 >> ,0
|
||||
测试获取产品 42 执行 142 all 没有主干 的分支信息 >> ,0
|
||||
测试获取产品 42 all 没有主干 的分支信息 >> ,0,3,4
|
||||
测试获取产品 42 执行 142 closed 没有主干 的分支信息 >> ,4
|
||||
测试获取产品 42 执行 142 active 没有主干 的分支信息 >> ,0,3
|
||||
测试获取产品 42 执行 142 all 没有主干 的分支信息 >> ,3,4
|
||||
测试获取产品 43的分支信息 >> ,0,5
|
||||
测试获取产品 43 执行 143的分支信息 >> ,0
|
||||
测试获取产品 43 执行 143 all 没有主干 的分支信息 >> ,0
|
||||
测试获取产品 43 all 没有主干 的分支信息 >> ,0,5,6
|
||||
测试获取产品 43 执行 143 closed 没有主干 的分支信息 >> ,6
|
||||
测试获取产品 43 执行 143 active 没有主干 的分支信息 >> ,0,5
|
||||
测试获取产品 43 执行 143 all 没有主干 的分支信息 >> ,5,6
|
||||
|
||||
*/
|
||||
$productID = array(41, 42, 43);
|
||||
$executionID = array(141, 142, 143, null);
|
||||
$browseType = array('all', 'closed', 'active');
|
||||
$mainBranch = false;
|
||||
|
||||
$branch = new branchTest();
|
||||
|
||||
r($branch->getListTest($productID[0])) && p() && e(',0,1'); // 测试获取产品 41的分支信息
|
||||
r($branch->getListTest($productID[0], $executionID[0])) && p() && e(',0'); // 测试获取产品 41 执行 141的分支信息
|
||||
r($branch->getListTest($productID[0], $executionID[0], $browseType[0])) && p() && e(',0'); // 测试获取产品 41 执行 141 all 没有主干 的分支信息
|
||||
r($branch->getListTest($productID[0], $executionID[3], $browseType[0])) && p() && e(',0,1,2'); // 测试获取产品 41 all 没有主干 的分支信息
|
||||
r($branch->getListTest($productID[0], $executionID[3], $browseType[1])) && p() && e(',2'); // 测试获取产品 41 执行 141 closed 没有主干 的分支信息
|
||||
r($branch->getListTest($productID[0], $executionID[3], $browseType[2])) && p() && e(',0,1'); // 测试获取产品 41 执行 141 active 没有主干 的分支信息
|
||||
r($branch->getListTest($productID[0], $executionID[3], $browseType[0], $mainBranch)) && p() && e(',1,2'); // 测试获取产品 41 执行 141 all 没有主干 的分支信息
|
||||
r($branch->getListTest($productID[1])) && p() && e(',0,3'); // 测试获取产品 42的分支信息
|
||||
r($branch->getListTest($productID[1], $executionID[1])) && p() && e(',0'); // 测试获取产品 42 执行 142的分支信息
|
||||
r($branch->getListTest($productID[1], $executionID[1], $browseType[0])) && p() && e(',0'); // 测试获取产品 42 执行 142 all 没有主干 的分支信息
|
||||
r($branch->getListTest($productID[1], $executionID[3], $browseType[0])) && p() && e(',0,3,4'); // 测试获取产品 42 all 没有主干 的分支信息
|
||||
r($branch->getListTest($productID[1], $executionID[3], $browseType[1])) && p() && e(',4'); // 测试获取产品 42 执行 142 closed 没有主干 的分支信息
|
||||
r($branch->getListTest($productID[1], $executionID[3], $browseType[2])) && p() && e(',0,3'); // 测试获取产品 42 执行 142 active 没有主干 的分支信息
|
||||
r($branch->getListTest($productID[1], $executionID[3], $browseType[0], $mainBranch)) && p() && e(',3,4'); // 测试获取产品 42 执行 142 all 没有主干 的分支信息
|
||||
r($branch->getListTest($productID[2])) && p() && e(',0,5'); // 测试获取产品 43的分支信息
|
||||
r($branch->getListTest($productID[2], $executionID[2])) && p() && e(',0'); // 测试获取产品 43 执行 143的分支信息
|
||||
r($branch->getListTest($productID[2], $executionID[2], $browseType[0])) && p() && e(',0'); // 测试获取产品 43 执行 143 all 没有主干 的分支信息
|
||||
r($branch->getListTest($productID[2], $executionID[3], $browseType[0])) && p() && e(',0,5,6'); // 测试获取产品 43 all 没有主干 的分支信息
|
||||
r($branch->getListTest($productID[2], $executionID[3], $browseType[1])) && p() && e(',6'); // 测试获取产品 43 执行 143 closed 没有主干 的分支信息
|
||||
r($branch->getListTest($productID[2], $executionID[3], $browseType[2])) && p() && e(',0,5'); // 测试获取产品 43 执行 143 active 没有主干 的分支信息
|
||||
r($branch->getListTest($productID[2], $executionID[3], $browseType[0], $mainBranch)) && p() && e(',5,6'); // 测试获取产品 43 执行 143 all 没有主干 的分支信息
|
||||
Executable
+63
@@ -0,0 +1,63 @@
|
||||
#!/usr/bin/env php
|
||||
<?php
|
||||
include dirname(dirname(dirname(__FILE__))) . '/lib/init.php';
|
||||
include dirname(dirname(dirname(__FILE__))) . '/class/branch.class.php';
|
||||
su('admin');
|
||||
|
||||
/**
|
||||
|
||||
title=测试 branchModel->getPairs();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
测试获取 产品41 的分支信息对 >> ,0,1,2
|
||||
测试获取 产品41 active 的分支信息对 >> ,0,1
|
||||
测试获取 产品41 noempty 的分支信息对 >> ,1,2
|
||||
测试获取 产品41 all 的分支信息对 >> ,all,0,1,2
|
||||
测试获取 产品41 withClosed 的分支信息对 >> ,0,1,2
|
||||
测试获取 产品41 active 执行141 的分支信息对 >> ,0
|
||||
测试获取 产品41 active 执行141 合并分支1 4 的分支信息对 >> ,0
|
||||
测试获取 产品41 的分支信息对 >> ,0,3,4
|
||||
测试获取 产品41 active 的分支信息对 >> ,0,3
|
||||
测试获取 产品41 noempty 的分支信息对 >> ,3,4
|
||||
测试获取 产品41 all 的分支信息对 >> ,all,0,3,4
|
||||
测试获取 产品41 withClosed 的分支信息对 >> ,0,3,4
|
||||
测试获取 产品41 active 执行141 的分支信息对 >> 0
|
||||
测试获取 产品41 active 执行141 合并分支1 4 的分支信息对 >> 0
|
||||
测试获取 产品41 的分支信息对 >> ,0,5,6
|
||||
测试获取 产品41 active 的分支信息对 >> ,0,5
|
||||
测试获取 产品41 noempty 的分支信息对 >> ,5,6
|
||||
测试获取 产品41 all 的分支信息对 >> ,all,0,5,6
|
||||
测试获取 产品41 withClosed 的分支信息对 >> ,0,5,6
|
||||
测试获取 产品41 active 执行141 的分支信息对 >> 0
|
||||
测试获取 产品41 active 执行141 合并分支1 4 的分支信息对 >> 0
|
||||
|
||||
*/
|
||||
$productID = array(41, 42, 43);
|
||||
$param = array('active', 'noempty', 'all', 'withClosed');
|
||||
$executionID = array(141, 142, 143, null);
|
||||
$mergedBranches = '1,4';
|
||||
|
||||
$branch = new branchTest();
|
||||
|
||||
r($branch->getPairsTest($productID[0])) && p() && e(',0,1,2'); // 测试获取 产品41 的分支信息对
|
||||
r($branch->getPairsTest($productID[0], $param[0])) && p() && e(',0,1'); // 测试获取 产品41 active 的分支信息对
|
||||
r($branch->getPairsTest($productID[0], $param[1])) && p() && e(',1,2'); // 测试获取 产品41 noempty 的分支信息对
|
||||
r($branch->getPairsTest($productID[0], $param[2])) && p() && e(',all,0,1,2'); // 测试获取 产品41 all 的分支信息对
|
||||
r($branch->getPairsTest($productID[0], $param[3])) && p() && e(',0,1,2'); // 测试获取 产品41 withClosed 的分支信息对
|
||||
r($branch->getPairsTest($productID[0], $param[0], $executionID[0])) && p() && e(',0'); // 测试获取 产品41 active 执行141 的分支信息对
|
||||
r($branch->getPairsTest($productID[0], $param[0], $executionID[0], $mergedBranches)) && p() && e(',0'); // 测试获取 产品41 active 执行141 合并分支1 4 的分支信息对
|
||||
r($branch->getPairsTest($productID[1])) && p() && e(',0,3,4'); // 测试获取 产品41 的分支信息对
|
||||
r($branch->getPairsTest($productID[1], $param[0])) && p() && e(',0,3'); // 测试获取 产品41 active 的分支信息对
|
||||
r($branch->getPairsTest($productID[1], $param[1])) && p() && e(',3,4'); // 测试获取 产品41 noempty 的分支信息对
|
||||
r($branch->getPairsTest($productID[1], $param[2])) && p() && e(',all,0,3,4'); // 测试获取 产品41 all 的分支信息对
|
||||
r($branch->getPairsTest($productID[1], $param[3])) && p() && e(',0,3,4'); // 测试获取 产品41 withClosed 的分支信息对
|
||||
r($branch->getPairsTest($productID[1], $param[0], $executionID[0])) && p() && e('0'); // 测试获取 产品41 active 执行141 的分支信息对
|
||||
r($branch->getPairsTest($productID[1], $param[0], $executionID[0], $mergedBranches)) && p() && e('0'); // 测试获取 产品41 active 执行141 合并分支1 4 的分支信息对
|
||||
r($branch->getPairsTest($productID[2])) && p() && e(',0,5,6'); // 测试获取 产品41 的分支信息对
|
||||
r($branch->getPairsTest($productID[2], $param[0])) && p() && e(',0,5'); // 测试获取 产品41 active 的分支信息对
|
||||
r($branch->getPairsTest($productID[2], $param[1])) && p() && e(',5,6'); // 测试获取 产品41 noempty 的分支信息对
|
||||
r($branch->getPairsTest($productID[2], $param[2])) && p() && e(',all,0,5,6'); // 测试获取 产品41 all 的分支信息对
|
||||
r($branch->getPairsTest($productID[2], $param[3])) && p() && e(',0,5,6'); // 测试获取 产品41 withClosed 的分支信息对
|
||||
r($branch->getPairsTest($productID[2], $param[0], $executionID[0])) && p() && e('0'); // 测试获取 产品41 active 执行141 的分支信息对
|
||||
r($branch->getPairsTest($productID[2], $param[0], $executionID[0], $mergedBranches)) && p() && e('0'); // 测试获取 产品41 active 执行141 合并分支1 4 的分支信息对
|
||||
+29
@@ -0,0 +1,29 @@
|
||||
#!/usr/bin/env php
|
||||
<?php
|
||||
include dirname(dirname(dirname(__FILE__))) . '/lib/init.php';
|
||||
include dirname(dirname(dirname(__FILE__))) . '/class/branch.class.php';
|
||||
su('admin');
|
||||
|
||||
/**
|
||||
|
||||
title=测试 branchModel->getPairsByProjectProduct();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
测试获取 项目 51 产品 41 的关联分支 >> 1:分支1;
|
||||
测试获取 项目 52 产品 42 的关联分支 >> 3:分支3;
|
||||
测试获取 项目 53 产品 43 的关联分支 >> 5:分支5;
|
||||
测试获取 项目 54 产品 44 的关联分支 >> 7:分支7;
|
||||
测试获取 项目 55 产品 45 的关联分支 >> 9:分支9;
|
||||
|
||||
*/
|
||||
$projectID = array(51, 52, 53, 54, 55);
|
||||
$productID = array(41, 42, 43, 44, 45);
|
||||
|
||||
$branch = new branchTest();
|
||||
|
||||
r($branch->getPairsByProjectProductTest($projectID[0], $productID[0])) && p() && e('1:分支1;'); // 测试获取 项目 51 产品 41 的关联分支
|
||||
r($branch->getPairsByProjectProductTest($projectID[1], $productID[1])) && p() && e('3:分支3;'); // 测试获取 项目 52 产品 42 的关联分支
|
||||
r($branch->getPairsByProjectProductTest($projectID[2], $productID[2])) && p() && e('5:分支5;'); // 测试获取 项目 53 产品 43 的关联分支
|
||||
r($branch->getPairsByProjectProductTest($projectID[3], $productID[3])) && p() && e('7:分支7;'); // 测试获取 项目 54 产品 44 的关联分支
|
||||
r($branch->getPairsByProjectProductTest($projectID[4], $productID[4])) && p() && e('9:分支9;'); // 测试获取 项目 55 产品 45 的关联分支
|
||||
Executable
+30
@@ -0,0 +1,30 @@
|
||||
#!/usr/bin/env php
|
||||
<?php
|
||||
include dirname(dirname(dirname(__FILE__))) . '/lib/init.php';
|
||||
include dirname(dirname(dirname(__FILE__))) . '/class/branch.class.php';
|
||||
su('admin');
|
||||
|
||||
/**
|
||||
|
||||
title=测试 branchModel->getProductType();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
测试获取分支 1 的项目类型 >> branch
|
||||
测试获取分支 3 的项目类型 >> branch
|
||||
测试获取分支 81 的项目类型 >> platform
|
||||
测试获取分支 83 的项目类型 >> platform
|
||||
测试获取分支 161 的项目类型 >> normal
|
||||
测试获取分支 163 的项目类型 >> normal
|
||||
|
||||
*/
|
||||
$branchID = array(1, 3, 81, 83, 161, 163);
|
||||
|
||||
$branch = new branchTest();
|
||||
|
||||
r($branch->getProductTypeTest($branchID[0])) && p() && e('branch'); // 测试获取分支 1 的项目类型
|
||||
r($branch->getProductTypeTest($branchID[1])) && p() && e('branch'); // 测试获取分支 3 的项目类型
|
||||
r($branch->getProductTypeTest($branchID[2])) && p() && e('platform'); // 测试获取分支 81 的项目类型
|
||||
r($branch->getProductTypeTest($branchID[3])) && p() && e('platform'); // 测试获取分支 83 的项目类型
|
||||
r($branch->getProductTypeTest($branchID[4])) && p() && e('normal'); // 测试获取分支 161 的项目类型
|
||||
r($branch->getProductTypeTest($branchID[5])) && p() && e('normal'); // 测试获取分支 163 的项目类型
|
||||
Executable
+30
@@ -0,0 +1,30 @@
|
||||
#!/usr/bin/env php
|
||||
<?php
|
||||
include dirname(dirname(dirname(__FILE__))) . '/lib/init.php';
|
||||
include dirname(dirname(dirname(__FILE__))) . '/class/branch.class.php';
|
||||
su('admin');
|
||||
|
||||
/**
|
||||
|
||||
title=测试 branchModel->linkBranch4Project();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
测试关联产品 41 的分支到项目 >> 4
|
||||
测试关联产品 42 的分支到项目 >> 4
|
||||
测试关联产品 43 的分支到项目 >> 4
|
||||
测试关联产品 44 的分支到项目 >> 4
|
||||
测试关联产品 45 的分支到项目 >> 4
|
||||
|
||||
*/
|
||||
|
||||
$productID = array(41, 42, 43, 44, 45);
|
||||
|
||||
$branch = new branchTest();
|
||||
|
||||
r($branch->linkBranch4ProjectTest($productID[0])) && p() && e('4'); // 测试关联产品 41 的分支到项目
|
||||
r($branch->linkBranch4ProjectTest($productID[1])) && p() && e('4'); // 测试关联产品 42 的分支到项目
|
||||
r($branch->linkBranch4ProjectTest($productID[2])) && p() && e('4'); // 测试关联产品 43 的分支到项目
|
||||
r($branch->linkBranch4ProjectTest($productID[3])) && p() && e('4'); // 测试关联产品 44 的分支到项目
|
||||
r($branch->linkBranch4ProjectTest($productID[4])) && p() && e('4'); // 测试关联产品 45 的分支到项目
|
||||
system("./ztest init");
|
||||
Executable
+43
@@ -0,0 +1,43 @@
|
||||
#!/usr/bin/env php
|
||||
<?php
|
||||
include dirname(dirname(dirname(__FILE__))) . '/lib/init.php';
|
||||
include dirname(dirname(dirname(__FILE__))) . '/class/branch.class.php';
|
||||
su('admin');
|
||||
|
||||
/**
|
||||
|
||||
title=测试 branchModel->mergeBranch();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
测试合并分支 1 到 分支 2 >> 2
|
||||
测试合并分支 2 到 新建分支 >> 2
|
||||
测试合并分支 3 4 到 主干 >> 12
|
||||
|
||||
*/
|
||||
$productID = array(41, 42);
|
||||
$mergedBranches = array('1', '2', '3,4');
|
||||
|
||||
$mergeBranch1 = new stdclass();
|
||||
$mergeBranch1->createBranch = 0;
|
||||
$mergeBranch1->mergedBranchIDList = array(1);
|
||||
$mergeBranch1->targetBranch = 2;
|
||||
|
||||
$mergeBranch2 = new stdclass();
|
||||
$mergeBranch2->name = '新建合并的分支';
|
||||
$mergeBranch2->desc = '合并分支的描述';
|
||||
$mergeBranch2->createBranch = 1;
|
||||
$mergeBranch2->mergedBranchIDList = array(2);
|
||||
$mergeBranch2->targetBranch = 0;
|
||||
|
||||
$mergeBranch3 = new stdclass();
|
||||
$mergeBranch3->createBranch = 0;
|
||||
$mergeBranch3->mergedBranchIDList = array(3, 4);
|
||||
$mergeBranch3->targetBranch = 0;
|
||||
|
||||
$branch = new branchTest();
|
||||
|
||||
r($branch->mergeBranchTest($productID[0], $mergedBranches[0], $mergeBranch1)) && p() && e('2'); // 测试合并分支 1 到 分支 2
|
||||
r($branch->mergeBranchTest($productID[0], $mergedBranches[1], $mergeBranch2)) && p() && e('2'); // 测试合并分支 2 到 新建分支
|
||||
r($branch->mergeBranchTest($productID[1], $mergedBranches[2], $mergeBranch3)) && p() && e('12'); // 测试合并分支 3 4 到 主干
|
||||
system("./ztest init");
|
||||
Executable
+44
@@ -0,0 +1,44 @@
|
||||
#!/usr/bin/env php
|
||||
<?php
|
||||
include dirname(dirname(dirname(__FILE__))) . '/lib/init.php';
|
||||
include dirname(dirname(dirname(__FILE__))) . '/class/branch.class.php';
|
||||
su('admin');
|
||||
|
||||
/**
|
||||
|
||||
title=测试 branchModel->showBranch();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
测试验证产品 1 是否显示分支标签 >> 2
|
||||
测试验证产品 1 模块 1821 是否显示分支标签 >> 2
|
||||
测试验证产品 1 执行 101 是否显示分支标签 >> 2
|
||||
测试验证产品 1 模块 1821 执行 101 是否显示分支标签 >> 2
|
||||
测试验证产品 41 是否显示分支标签 >> 1
|
||||
测试验证产品 41 模块 1981 是否显示分支标签 >> 1
|
||||
测试验证产品 41 执行 231 是否显示分支标签 >> 1
|
||||
测试验证产品 41 模块 1981 执行 231 是否显示分支标签 >> 1
|
||||
测试验证产品 81 是否显示分支标签 >> 1
|
||||
测试验证产品 81 模块 2141 是否显示分支标签 >> 1
|
||||
测试验证产品 81 执行 181 是否显示分支标签 >> 1
|
||||
测试验证产品 81 模块 2141 执行 181 是否显示分支标签 >> 1
|
||||
|
||||
*/
|
||||
$productID = array(1, 41, 81);
|
||||
$moduleID = array(0, 1821, 1981, 2141);
|
||||
$executionID = array(0, 101, 231, 181);
|
||||
|
||||
$branch = new branchTest();
|
||||
|
||||
r($branch->showBranchTest($productID[0])) && p() && e('2'); // 测试验证产品 1 是否显示分支标签
|
||||
r($branch->showBranchTest($productID[0], $moduleID[1])) && p() && e('2'); // 测试验证产品 1 模块 1821 是否显示分支标签
|
||||
r($branch->showBranchTest($productID[0], $moduleID[0], $executionID[1])) && p() && e('2'); // 测试验证产品 1 执行 101 是否显示分支标签
|
||||
r($branch->showBranchTest($productID[0], $moduleID[1], $executionID[1])) && p() && e('2'); // 测试验证产品 1 模块 1821 执行 101 是否显示分支标签
|
||||
r($branch->showBranchTest($productID[1])) && p() && e('1'); // 测试验证产品 41 是否显示分支标签
|
||||
r($branch->showBranchTest($productID[1], $moduleID[2])) && p() && e('1'); // 测试验证产品 41 模块 1981 是否显示分支标签
|
||||
r($branch->showBranchTest($productID[1], $moduleID[0], $executionID[2])) && p() && e('1'); // 测试验证产品 41 执行 231 是否显示分支标签
|
||||
r($branch->showBranchTest($productID[1], $moduleID[2], $executionID[2])) && p() && e('1'); // 测试验证产品 41 模块 1981 执行 231 是否显示分支标签
|
||||
r($branch->showBranchTest($productID[2])) && p() && e('1'); // 测试验证产品 81 是否显示分支标签
|
||||
r($branch->showBranchTest($productID[2], $moduleID[3])) && p() && e('1'); // 测试验证产品 81 模块 2141 是否显示分支标签
|
||||
r($branch->showBranchTest($productID[2], $moduleID[0], $executionID[3])) && p() && e('1'); // 测试验证产品 81 执行 181 是否显示分支标签
|
||||
r($branch->showBranchTest($productID[2], $moduleID[3], $executionID[3])) && p() && e('1'); // 测试验证产品 81 模块 2141 执行 181 是否显示分支标签
|
||||
Executable
+36
@@ -0,0 +1,36 @@
|
||||
#!/usr/bin/env php
|
||||
<?php
|
||||
include dirname(dirname(dirname(__FILE__))) . '/lib/init.php';
|
||||
include dirname(dirname(dirname(__FILE__))) . '/class/branch.class.php';
|
||||
su('admin');
|
||||
|
||||
/**
|
||||
|
||||
title=测试 branchModel->sort();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
测试产品 41 排序 >> 1,2
|
||||
测试产品 42 排序 >> 3,4
|
||||
测试产品 43 排序 >> 5,6
|
||||
测试产品 44 排序 >> 7,8
|
||||
测试产品 41 order 排序 >> 2,1
|
||||
测试产品 42 order 排序 >> 4,3
|
||||
测试产品 43 order 排序 >> 6,5
|
||||
测试产品 44 order 排序 >> 8,7
|
||||
|
||||
*/
|
||||
$branches = array('0,2,1', '0,4,3', '0,6,5', '0,8,7');
|
||||
$order = 'order';
|
||||
|
||||
$branch = new branchTest();
|
||||
|
||||
r($branch->sortTest($branches[0])) && p() && e('1,2'); // 测试产品 41 排序
|
||||
r($branch->sortTest($branches[1])) && p() && e('3,4'); // 测试产品 42 排序
|
||||
r($branch->sortTest($branches[2])) && p() && e('5,6'); // 测试产品 43 排序
|
||||
r($branch->sortTest($branches[3])) && p() && e('7,8'); // 测试产品 44 排序
|
||||
r($branch->sortTest($branches[0], $order)) && p() && e('2,1'); // 测试产品 41 order 排序
|
||||
r($branch->sortTest($branches[1], $order)) && p() && e('4,3'); // 测试产品 42 order 排序
|
||||
r($branch->sortTest($branches[2], $order)) && p() && e('6,5'); // 测试产品 43 order 排序
|
||||
r($branch->sortTest($branches[3], $order)) && p() && e('8,7'); // 测试产品 44 order 排序
|
||||
system("./ztest init");
|
||||
Executable
+27
@@ -0,0 +1,27 @@
|
||||
#!/usr/bin/env php
|
||||
<?php
|
||||
include dirname(dirname(dirname(__FILE__))) . '/lib/init.php';
|
||||
include dirname(dirname(dirname(__FILE__))) . '/class/branch.class.php';
|
||||
su('admin');
|
||||
|
||||
/**
|
||||
|
||||
title=测试 branchModel->unlinkBranch4Project();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
测试产品 41 转为普通产品接触分支关联 >> 0
|
||||
测试产品 42 转为普通产品接触分支关联 >> 0
|
||||
测试产品 43 转为普通产品接触分支关联 >> 0
|
||||
测试产品 44 45 转为普通产品接触分支关联 >> 0
|
||||
|
||||
*/
|
||||
$productIDList = array('41', '42', '43', '44,45');
|
||||
|
||||
$branch = new branchTest();
|
||||
|
||||
r($branch->unlinkBranch4ProjectTest($productIDList[0])) && p() && e('0'); // 测试产品 41 转为普通产品接触分支关联
|
||||
r($branch->unlinkBranch4ProjectTest($productIDList[1])) && p() && e('0'); // 测试产品 42 转为普通产品接触分支关联
|
||||
r($branch->unlinkBranch4ProjectTest($productIDList[2])) && p() && e('0'); // 测试产品 43 转为普通产品接触分支关联
|
||||
r($branch->unlinkBranch4ProjectTest($productIDList[3])) && p() && e('0'); // 测试产品 44 45 转为普通产品接触分支关联
|
||||
system("./ztest init");
|
||||
Executable
+33
@@ -0,0 +1,33 @@
|
||||
#!/usr/bin/env php
|
||||
<?php
|
||||
include dirname(dirname(dirname(__FILE__))) . '/lib/init.php';
|
||||
include dirname(dirname(dirname(__FILE__))) . '/class/branch.class.php';
|
||||
su('admin');
|
||||
|
||||
/**
|
||||
|
||||
title=测试 branchModel->update();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
测试修改分支名称 >> name,分支1,修改后的分支1
|
||||
测试修改分支状态 >> status,active,closed
|
||||
测试修改分支描述 >> desc,,修改后的分支1描述
|
||||
测试修改分支名称 >> 『名称』不能为空。
|
||||
测试修改分支名称 >> 分支名称已存在
|
||||
|
||||
*/
|
||||
$changeName = array('name' => '修改后的分支1');
|
||||
$changeStatus = array('status' => 'closed');
|
||||
$changeDesc = array('desc' => '修改后的分支1描述');
|
||||
$emptyName = array('name' => '');
|
||||
$repeatName = array('name' => '分支2');
|
||||
|
||||
$branch = new branchTest();
|
||||
|
||||
r($branch->updateTest($changeName)) && p('0:field,old,new') && e('name,分支1,修改后的分支1'); // 测试修改分支名称
|
||||
r($branch->updateTest($changeStatus)) && p('0:field,old,new') && e('status,active,closed'); // 测试修改分支状态
|
||||
r($branch->updateTest($changeDesc)) && p('0:field,old,new') && e('desc,,修改后的分支1描述'); // 测试修改分支描述
|
||||
r($branch->updateTest($emptyName)) && p('name:0') && e('『名称』不能为空。'); // 测试修改分支名称
|
||||
r($branch->updateTest($repeatName)) && p('name:0') && e('分支名称已存在'); // 测试修改分支名称
|
||||
system("./ztest init");
|
||||
@@ -10,6 +10,17 @@ title=测试 kanbanModel->activateCard();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
测试激活卡片1,进度0 >> 1,卡片1,doing,0
|
||||
测试激活卡片1,进度50 >> 1,卡片1,doing,50
|
||||
测试激活卡片1,进度100 >> 请输入正确的进度
|
||||
测试激活卡片1,进度101 >> 请输入正确的进度
|
||||
测试激活卡片1,进度-1 >> 请输入正确的进度
|
||||
测试激活卡片2,进度0 >> 2,卡片2,doing,0
|
||||
测试激活卡片3,进度0 >> 3,卡片3,doing,50
|
||||
测试激活卡片4,进度0 >> 4,卡片4,doing,0
|
||||
测试激活卡片5,进度0 >> 5,卡片5,doing,50
|
||||
测试激活不存在的卡片,进度0 >> 0
|
||||
|
||||
*/
|
||||
|
||||
$cardIDList = array('1', '2', '3', '4', '5', '100001');
|
||||
@@ -27,4 +38,4 @@ r($kanban->activateCardTest($cardIDList[2], $progressList[1])) && p('id,name,sta
|
||||
r($kanban->activateCardTest($cardIDList[3], $progressList[0])) && p('id,name,status,progress') && e('4,卡片4,doing,0'); // 测试激活卡片4,进度0
|
||||
r($kanban->activateCardTest($cardIDList[4], $progressList[1])) && p('id,name,status,progress') && e('5,卡片5,doing,50'); // 测试激活卡片5,进度0
|
||||
r($kanban->activateCardTest($cardIDList[5], $progressList[0])) && p('id,name,status,progress') && e('0'); // 测试激活不存在的卡片,进度0
|
||||
system("./ztest init");
|
||||
system("./ztest init");
|
||||
@@ -10,6 +10,23 @@ title=测试 kanbanModel->addKanbanCell();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
更新类型为common的kanbancell >> common,,0,1,2,
|
||||
更新类型为common的kanbancell 有cardID >> common,,3,0,1,2,
|
||||
插入类型为common的kanbancell >> common,
|
||||
插入类型为common的kanbancell 有cardID >> common,,3,
|
||||
更新类型为story的kanbancell >> story,,0,
|
||||
更新类型为story的kanbancell 有cardID >> story,,3,0,
|
||||
插入类型为story的kanbancell >> story,
|
||||
插入类型为story的kanbancell 有cardID >> story,,3,
|
||||
更新类型为bug的kanbancell >> bug,,0,
|
||||
更新类型为bug的kanbancell 有cardID >> bug,,3,0,
|
||||
插入类型为bug的kanbancell >> bug,
|
||||
插入类型为bug的kanbancell 有cardID >> bug,,3,
|
||||
更新类型为task的kanbancell >> task,,0,
|
||||
更新类型为task的kanbancell 有cardID >> task,,3,0,
|
||||
插入类型为task的kanbancell >> task,
|
||||
插入类型为task的kanbancell 有cardID >> task,,3,
|
||||
|
||||
*/
|
||||
|
||||
$kanban = new kanbanTest();
|
||||
@@ -36,4 +53,4 @@ r($kanban->addKanbanCellTest($kanbanIDList[1], $laneIDList[3], $columnIDList[3],
|
||||
r($kanban->addKanbanCellTest($kanbanIDList[1], $laneIDList[3], $columnIDList[3], $typeList[3], $cardID)) && p('type,cards') && e('task,,3,0,'); // 更新类型为task的kanbancell 有cardID
|
||||
r($kanban->addKanbanCellTest($kanbanIDList[1], $laneIDList[3], $columnIDList[0], $typeList[3])) && p('type,cards') && e('task,'); // 插入类型为task的kanbancell
|
||||
r($kanban->addKanbanCellTest($kanbanIDList[1], $laneIDList[3], $columnIDList[0], $typeList[3], $cardID)) && p('type,cards') && e('task,,3,'); // 插入类型为task的kanbancell 有cardID
|
||||
system("./ztest init");
|
||||
system("./ztest init");
|
||||
@@ -10,6 +10,12 @@ title=测试 kanbanModel->archiveCard();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
测试归档卡片1 >> archived,0,1
|
||||
测试归档卡片2 >> archived,0,1
|
||||
测试归档卡片3 >> archived,0,1
|
||||
测试归档卡片4 >> archived,0,1
|
||||
测试归档卡片5 >> archived,0,1
|
||||
|
||||
*/
|
||||
|
||||
$cardIDList = array('1', '2', '3', '4', '5');
|
||||
@@ -21,4 +27,4 @@ r($kanban->archiveCardTest($cardIDList[1])) && p('0:field,old,new') && e('archiv
|
||||
r($kanban->archiveCardTest($cardIDList[2])) && p('0:field,old,new') && e('archived,0,1'); // 测试归档卡片3
|
||||
r($kanban->archiveCardTest($cardIDList[3])) && p('0:field,old,new') && e('archived,0,1'); // 测试归档卡片4
|
||||
r($kanban->archiveCardTest($cardIDList[4])) && p('0:field,old,new') && e('archived,0,1'); // 测试归档卡片5
|
||||
system("./ztest init");
|
||||
system("./ztest init");
|
||||
@@ -10,6 +10,13 @@ title=测试 kanbanModel->archiveColumn();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
测试归档列1 >> 1,1
|
||||
测试归档列2 >> 2,1
|
||||
测试归档列3 >> 3,1
|
||||
测试归档列4 >> 4,1
|
||||
测试归档列5 >> 5,1
|
||||
测试归档不存在的列 >> 0
|
||||
|
||||
*/
|
||||
|
||||
$columnIDList = array('1', '2', '3', '4', '5', '1000001');
|
||||
@@ -22,4 +29,4 @@ r($kanban->archiveColumnTest($columnIDList[2])) && p('id,archived') && e('3,1');
|
||||
r($kanban->archiveColumnTest($columnIDList[3])) && p('id,archived') && e('4,1'); // 测试归档列4
|
||||
r($kanban->archiveColumnTest($columnIDList[4])) && p('id,archived') && e('5,1'); // 测试归档列5
|
||||
r($kanban->archiveColumnTest($columnIDList[5])) && p() && e('0'); // 测试归档不存在的列
|
||||
system("./ztest init");
|
||||
system("./ztest init");
|
||||
@@ -10,6 +10,11 @@ title=测试 kanbanModel->batchCreateCard();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
批量创建卡片 其中一个没有名称 >> 1,1,1,common,,1003,1002,1001,1,2,801,
|
||||
批量创建卡片 预计为负数 >> 预计不能为负数!
|
||||
批量创建看板 截止日期小于开始日期 >> "截止日期"不能小于"预计开始"!
|
||||
批量创建看板 >> 1,1,1,common,,1010,1009,1008,1007,1004,1003,1002,1001,1,2,801,
|
||||
|
||||
*/
|
||||
|
||||
$no_name = array('0' => '', '1' => '批量创建的卡片2', '2' => '批量创建的卡片3', '3' => '批量创建的卡片4');
|
||||
@@ -22,4 +27,4 @@ r($kanban->batchCreateCardTest(array('name' => $no_name))) && p('kanban,col
|
||||
r($kanban->batchCreateCardTest(array('estimate' => $estimate))) && p() && e('预计不能为负数!'); // 批量创建卡片 预计为负数
|
||||
r($kanban->batchCreateCardTest(array(), true)) && p() && e('"截止日期"不能小于"预计开始"!'); // 批量创建看板 截止日期小于开始日期
|
||||
r($kanban->batchCreateCardTest()) && p('kanban,column,lane,type,cards') && e('1,1,1,common,,1010,1009,1008,1007,1004,1003,1002,1001,1,2,801,'); // 批量创建看板
|
||||
system("./ztest init");
|
||||
system("./ztest init");
|
||||
@@ -10,6 +10,13 @@ title=测试 kanbanModel->create();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
创建协同空间 >> 测试创建协作看板,1,,po15,
|
||||
创建私人空间 >> 测试创建私人看板,2,,admin,,user4
|
||||
创建公共空间 >> 测试创建公共看板,3,,po17,
|
||||
创建没有名字的公共空间 >> 『看板名称』不能为空。
|
||||
创建没有空间公共空间 >> 『所属空间』不能为空。
|
||||
创建重名公共空间 >> 『看板名称』已经有『测试创建公共看板』这条记录了。如果您确定该记录已删除,请到后台-系统-数据-回收站还原。
|
||||
|
||||
*/
|
||||
|
||||
$kanban1 = new stdclass();
|
||||
@@ -68,4 +75,4 @@ r($kanban->createTest($kanban3)) && p('name,space,type,owner,whitelist') && e('
|
||||
r($kanban->createTest($kanban4)) && p('name:0') && e('『看板名称』不能为空。'); // 创建没有名字的公共空间
|
||||
r($kanban->createTest($kanban5)) && p('space:0') && e('『所属空间』不能为空。'); // 创建没有空间公共空间
|
||||
r($kanban->createTest($kanban6)) && p('name:0') && e('『看板名称』已经有『测试创建公共看板』这条记录了。如果您确定该记录已删除,请到后台-系统-数据-回收站还原。'); // 创建重名公共空间
|
||||
system("./ztest init");
|
||||
system("./ztest init");
|
||||
@@ -10,6 +10,12 @@ title=测试 kanbanModel->createCard();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
测试创建卡片1 >> 测试创建卡片1,1,1,测试创建卡片1的卡片描述
|
||||
测试创建卡片2 >> 测试创建卡片2,2,2,测试创建卡片2的卡片描述
|
||||
测试创建预计小于0的卡片 >> 预计不能为负数!
|
||||
测试创建结束小于开始日期的卡片 >> "截止日期"不能小于"预计开始"!
|
||||
测试创建没有名字的卡片 >> 『卡片名称』不能为空。
|
||||
|
||||
*/
|
||||
|
||||
$card1 = new stdclass();
|
||||
@@ -56,4 +62,4 @@ r($kanban->createCardTest($card2)) && p('name,pri,estimate,desc') && e('测试
|
||||
r($kanban->createCardTest($card3)) && p('estimate') && e('预计不能为负数!'); // 测试创建预计小于0的卡片
|
||||
r($kanban->createCardTest($card4)) && p('end') && e('"截止日期"不能小于"预计开始"!'); // 测试创建结束小于开始日期的卡片
|
||||
r($kanban->createCardTest($card5)) && p('name:0') && e('『卡片名称』不能为空。'); // 测试创建没有名字的卡片
|
||||
system("./ztest init");
|
||||
system("./ztest init");
|
||||
@@ -10,6 +10,15 @@ title=测试 kanbanModel->createColumn();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
创建没有在制品限制的看板列 >> 测试创建不限制看板列,-1,#333,0,1
|
||||
创建没有在制品限制的看板列 >> 测试创建不限制子看板列,-1,#333,1,1
|
||||
创建有在制品限制的看板列 >> 测试创建限制父看板列,111,#333,-1,1
|
||||
创建有在制品限制的子看板列 >> 测试创建限制子看板列,11,#333,5263,1
|
||||
创建没有名称的看板列 >> 『看板列名称』不能为空。
|
||||
创建没有填写在制品限制的看板列 >> 在制品数量必须是正整数。
|
||||
创建在制品数量为0的看板列 >> 在制品数量必须是正整数。
|
||||
创建在制品数量超出限制的子看板列 >> 父列的在制品数量不能小于子列在制品数量之和
|
||||
|
||||
*/
|
||||
|
||||
$column1 = new stdclass();
|
||||
@@ -86,4 +95,4 @@ r($kanban->createColumnTest($column5)) && p('name:0') &&
|
||||
r($kanban->createColumnTest($column6)) && p('limit') && e('在制品数量必须是正整数。'); // 创建没有填写在制品限制的看板列
|
||||
r($kanban->createColumnTest($column7)) && p('limit') && e('在制品数量必须是正整数。'); // 创建在制品数量为0的看板列
|
||||
r($kanban->createColumnTest($column8)) && p('limit:0') && e('父列的在制品数量不能小于子列在制品数量之和'); // 创建在制品数量超出限制的子看板列
|
||||
system("./ztest init");
|
||||
system("./ztest init");
|
||||
@@ -10,6 +10,13 @@ title=测试 kanbanModel->createDefaultColumns();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
创建region 1 group 1的默认泳道列 >> 8
|
||||
创建region 2 group 2的默认泳道列 >> 8
|
||||
创建region 3 group 3的默认泳道列 >> 8
|
||||
创建region 4 group 4的默认泳道列 >> 8
|
||||
创建region 5 group 5的默认泳道列 >> 8
|
||||
重复创建region 1 group 1的默认泳道列 >> 12
|
||||
|
||||
*/
|
||||
|
||||
$kanban = new kanbanTest();
|
||||
@@ -23,4 +30,4 @@ r($kanban->createDefaultColumnsTest($regionIDList[2], $groupIDList[2])) && p() &
|
||||
r($kanban->createDefaultColumnsTest($regionIDList[3], $groupIDList[3])) && p() && e('8'); // 创建region 4 group 4的默认泳道列
|
||||
r($kanban->createDefaultColumnsTest($regionIDList[4], $groupIDList[4])) && p() && e('8'); // 创建region 5 group 5的默认泳道列
|
||||
r($kanban->createDefaultColumnsTest($regionIDList[0], $groupIDList[0])) && p() && e('12'); // 重复创建region 1 group 1的默认泳道列
|
||||
system("./ztest init");
|
||||
system("./ztest init");
|
||||
@@ -10,6 +10,12 @@ title=测试 kanbanModel->createDefaultLane();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
创建region 1 group 1的默认泳道 >> 默认泳道,1,1,common
|
||||
创建region 2 group 2的默认泳道 >> 默认泳道,2,2,common
|
||||
创建region 3 group 3的默认泳道 >> 默认泳道,3,3,common
|
||||
创建region 4 group 4的默认泳道 >> 默认泳道,4,4,common
|
||||
创建region 5 group 5的默认泳道 >> 默认泳道,5,5,common
|
||||
|
||||
*/
|
||||
|
||||
$kanban = new kanbanTest();
|
||||
@@ -22,4 +28,4 @@ r($kanban->createDefaultLaneTest($regionIDList[1], $groupIDList[1])) && p('name,
|
||||
r($kanban->createDefaultLaneTest($regionIDList[2], $groupIDList[2])) && p('name,group,region,type') && e('默认泳道,3,3,common'); // 创建region 3 group 3的默认泳道
|
||||
r($kanban->createDefaultLaneTest($regionIDList[3], $groupIDList[3])) && p('name,group,region,type') && e('默认泳道,4,4,common'); // 创建region 4 group 4的默认泳道
|
||||
r($kanban->createDefaultLaneTest($regionIDList[4], $groupIDList[4])) && p('name,group,region,type') && e('默认泳道,5,5,common'); // 创建region 5 group 5的默认泳道
|
||||
system("./ztest init");
|
||||
system("./ztest init");
|
||||
@@ -10,6 +10,12 @@ title=测试 kanbanModel->createDefaultRegion();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
创建看板10001的默认区域 >> 10001,10001,默认区域
|
||||
创建看板10002的默认区域 >> 10002,10002,默认区域
|
||||
创建看板10003的默认区域 >> 10003,10003,默认区域
|
||||
创建看板10004的默认区域 >> 10004,10004,默认区域
|
||||
重复创建看板1的默认区域 >> 『区域名称』已经有『默认区域』这条记录了。如果您确定该记录已删除,请到后台-系统-数据-回收站还原。
|
||||
|
||||
*/
|
||||
|
||||
$kanban1 = new stdclass();
|
||||
@@ -39,4 +45,4 @@ r($kanban->createDefaultRegionTest($kanban2)) && p('space,kanban,name') && e('10
|
||||
r($kanban->createDefaultRegionTest($kanban3)) && p('space,kanban,name') && e('10003,10003,默认区域'); // 创建看板10003的默认区域
|
||||
r($kanban->createDefaultRegionTest($kanban4)) && p('space,kanban,name') && e('10004,10004,默认区域'); // 创建看板10004的默认区域
|
||||
r($kanban->createDefaultRegionTest($kanban5)) && p('name:0') && e('『区域名称』已经有『默认区域』这条记录了。如果您确定该记录已删除,请到后台-系统-数据-回收站还原。'); // 重复创建看板1的默认区域
|
||||
system("./ztest init");
|
||||
system("./ztest init");
|
||||
@@ -10,6 +10,22 @@ title=测试 kanbanModel->createExecutionColumns();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
创建泳道 100001 执行101 需求的看板列 >> 11
|
||||
创建泳道 100001 执行101 任务的看板列 >> 7
|
||||
创建泳道 100001 执行101 bug 的看板列 >> 9
|
||||
创建泳道 100002 执行102 需求的看板列 >> 11
|
||||
创建泳道 100002 执行102 任务的看板列 >> 7
|
||||
创建泳道 100002 执行102 bug 的看板列 >> 14
|
||||
创建泳道 100003 执行103 需求的看板列 >> 11
|
||||
创建泳道 100003 执行103 任务的看板列 >> 7
|
||||
创建泳道 100003 执行103 bug 的看板列 >> 9
|
||||
创建泳道 100004 执行104 需求的看板列 >> 11
|
||||
创建泳道 100004 执行104 任务的看板列 >> 7
|
||||
创建泳道 100004 执行104 bug 的看板列 >> 9
|
||||
创建泳道 100005 执行105 需求的看板列 >> 11
|
||||
创建泳道 100005 执行105 任务的看板列 >> 7
|
||||
创建泳道 100005 执行105 bug 的看板列 >> 9
|
||||
|
||||
*/
|
||||
|
||||
$laneIDList = array('100001', '100002', '100003', '10004', '10005');
|
||||
@@ -33,4 +49,4 @@ r($kanban->createExecutionColumnsTest($laneIDList[3], $typeList[2], $executionID
|
||||
r($kanban->createExecutionColumnsTest($laneIDList[4], $typeList[0], $executionIDList[4])) && p() && e('11'); // 创建泳道 100005 执行105 需求的看板列
|
||||
r($kanban->createExecutionColumnsTest($laneIDList[4], $typeList[1], $executionIDList[4])) && p() && e('7'); // 创建泳道 100005 执行105 任务的看板列
|
||||
r($kanban->createExecutionColumnsTest($laneIDList[4], $typeList[2], $executionIDList[4])) && p() && e('9'); // 创建泳道 100005 执行105 bug 的看板列
|
||||
system("./ztest init");
|
||||
system("./ztest init");
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user