From 3066ab33df2ea2f8f4a8406c50ba56fc677406d7 Mon Sep 17 00:00:00 2001 From: caoyanyi Date: Mon, 9 Jan 2023 16:53:42 +0800 Subject: [PATCH] * Update uni test. --- test/model/execution/start.php | 20 +++++++++++++------- test/model/execution/suspend.php | 2 +- 2 files changed, 14 insertions(+), 8 deletions(-) diff --git a/test/model/execution/start.php b/test/model/execution/start.php index 1f52ea7577..8c320959f1 100755 --- a/test/model/execution/start.php +++ b/test/model/execution/start.php @@ -2,7 +2,14 @@ switchDB(); + +$execution = zdTable('project'); +$execution->id->range('1-6'); +$execution->name->range('项目1,迭代1,迭代2,迭代3,迭代4,迭代5'); +$execution->type->range('project,sprint{2},waterfall{2},kanban{1}'); +$execution->parent->range('0,1{3},2{2}'); +$execution->status->range('wait'); +$execution->gen(6); su('admin'); /** @@ -11,15 +18,15 @@ title=测试executionModel->startTest(); cid=1 pid=1 -敏捷执行开始 >> status,wait,doing -瀑布阶段开始 >> status,wait,doing -看板执行开始 >> status,wait,doing -重复执行开始 >> 此任务已被启动,不能重复启动! +敏捷执行开始 >> status,wait,doing +瀑布阶段开始 >> status,wait,doing +看板执行开始 >> status,wait,doing +重复执行开始 >> 此任务已被启动,不能重复启动! 子瀑布开启获取父瀑布状态 >> doing */ -$executionIDList = array('101', '131', '161', '103', '701'); +$executionIDList = array('2', '3', '4', '5'); $noRealBegan = array('realBegan' => ''); @@ -29,4 +36,3 @@ r($execution->startTest($executionIDList[1])) && p('1:field,old,n r($execution->startTest($executionIDList[2])) && p('1:field,old,new') && e('status,wait,doing'); // 看板执行开始 r($execution->startTest($executionIDList[0],$noRealBegan)) && p() && e('此任务已被启动,不能重复启动!'); // 重复执行开始 r($execution->startTest($executionIDList[3], array(), true)) && p('status') && e('doing'); // 子瀑布开启获取父瀑布状态 -$db->restoreDB(); diff --git a/test/model/execution/suspend.php b/test/model/execution/suspend.php index 54987d06c8..4a771b56a0 100755 --- a/test/model/execution/suspend.php +++ b/test/model/execution/suspend.php @@ -6,7 +6,7 @@ include dirname(dirname(dirname(__FILE__))) . '/class/execution.class.php'; $execution = zdTable('project'); $execution->id->range('1-7'); $execution->name->range('项目1,迭代1,迭代2,迭代3,迭代4,迭代5,迭代6'); -$execution->type->range('project{2},sprint{2},waterfall{2},kanban{2}'); +$execution->type->range('project,sprint{2},waterfall{2},kanban{2}'); $execution->status->range('doing,wait'); $execution->gen(7);