* [ci,done,0.1h] fix setmenu unit test.
This commit is contained in:
@@ -2,6 +2,20 @@
|
||||
<?php
|
||||
include dirname(__FILE__, 5) . '/test/lib/init.php';
|
||||
include dirname(__FILE__, 2) . '/lib/execution.unittest.class.php';
|
||||
/**
|
||||
|
||||
title=测试 executionModel::setMenu();
|
||||
timeout=0
|
||||
cid=1
|
||||
|
||||
- 测试构建导航第build条的link属性 @构建|execution|build|executionID=5
|
||||
- 测试设置迭代导航第more条的link属性 @更多|execution|more|5
|
||||
- 测试设置阶段导航第more条的link属性 @更多|execution|more|5
|
||||
- 测试设置看板导航第kanban条的link属性 @看板|execution|kanban|executionID=5
|
||||
- 执行不存在的情况 @0
|
||||
- 执行不存在的情况 @0
|
||||
|
||||
*/
|
||||
|
||||
zenData('user')->gen(5);
|
||||
su('admin');
|
||||
@@ -17,23 +31,10 @@ $execution->begin->range('20220112 000000:0')->type('timestamp')->format('YY/MM/
|
||||
$execution->end->range('20220212 000000:0')->type('timestamp')->format('YY/MM/DD');
|
||||
$execution->gen(5);
|
||||
|
||||
/**
|
||||
|
||||
title=测试 executionModel::setMenu();
|
||||
timeout=0
|
||||
cid=1
|
||||
|
||||
- 测试构建导航第build条的link属性 @构建|execution|build|executionID=5
|
||||
- 测试设置迭代导航第more条的link属性 @更多|execution|more|5
|
||||
- 测试设置阶段导航第more条的link属性 @更多|execution|more|5
|
||||
- 测试设置看板导航第kanban条的link属性 @看板|execution|kanban|executionID=5
|
||||
- 执行不存在的情况 @0
|
||||
|
||||
*/
|
||||
|
||||
$executionTester = new executionTest();
|
||||
r($executionTester->setMenuTest(2)) && p('build:link') && e('构建|execution|build|executionID=5'); // 测试构建导航
|
||||
r($executionTester->setMenuTest(3)) && p('more:link') && e('更多|execution|more|5'); // 测试设置迭代导航
|
||||
r($executionTester->setMenuTest(4)) && p('more:link') && e('更多|execution|more|5'); // 测试设置阶段导航
|
||||
r($executionTester->setMenuTest(5)) && p('kanban:link') && e('看板|execution|kanban|executionID=5'); // 测试设置看板导航
|
||||
r($executionTester->setMenuTest(6)) && p() && e('0'); // 执行不存在的情况
|
||||
r($executionTester->setMenuTest(10)) && p() && e('0'); // 执行不存在的情况
|
||||
|
||||
Reference in New Issue
Block a user