* Modify the kanban module test case.

This commit is contained in:
tianshujie
2022-05-20 09:00:48 +08:00
parent 3742cf99d0
commit 1e65c36b18
2 changed files with 6 additions and 2 deletions
+4 -2
View File
@@ -519,10 +519,11 @@ class kanbanTest
* @param int $kanbanID
* @param string $fromType
* @param int $archived
* @param int $regionID
* @access public
* @return string
*/
public function getImportedCardsTest($kanbanID, $fromType, $archived = 0)
public function getImportedCardsTest($kanbanID, $fromType, $archived = 0, $regionID = 0)
{
global $tester;
$cards = $tester->dao->select('*')->from(TABLE_KANBANCARD)
@@ -530,9 +531,10 @@ class kanbanTest
->andWhere('kanban')->eq($kanbanID)
->andWhere('archived')->eq($archived)
->andWhere('fromID')->eq(0)
->beginIF($regionID)->andWhere('region')->eq($regionID)->fi()
->fetchAll('id');
$objects = $this->objectModel->getImportedCards($kanbanID, $cards, $fromType, $archived);
$objects = $this->objectModel->getImportedCards($kanbanID, $cards, $fromType, $archived, $regionID);
if(dao::isError()) return dao::getError();
+2
View File
@@ -27,6 +27,7 @@ pid=1
查看看板25的普通卡片和build卡片 >> ,193,194,195,196,197,198,199,200,993,994,995,996,997,998,999,1000
查看看板25的普通卡片和productplan片 >> ,193,194,195,196,197,198,199,200
查看看板1已归档的普通卡片和productplan卡片 >> ,6,7,8,801,802,803,804,805,806,807,808
查看区域ID=1中看板1已归档的普通卡片和productplan卡片 >> ,6,7,8,801,802,803,804,805,806,807,808
*/
@@ -55,4 +56,5 @@ r($kanban->getImportedCardstest($kanbanIDList[7], $fromType[0])) && p() && e(',1
global $tester;
$tester->dao->update(TABLE_KANBANCARD)->set('archived')->eq(1)->where('id')->gt('5')->exec();
r($kanban->getImportedCardsTest($kanbanIDList[0], $fromType[0], $archived)) && p() && e(',6,7,8,801,802,803,804,805,806,807,808'); // 查看看板1已归档的普通卡片和productplan卡片
r($kanban->getImportedCardsTest($kanbanIDList[0], $fromType[0], $archived, 1)) && p() && e(',6,7,8,801,802,803,804,805,806,807,808'); // 查看区域ID=1中看板1已归档的普通卡片和productplan卡片
$tester->dao->update(TABLE_KANBANCARD)->set('archived')->eq(0)->where('id')->gt('5')->exec();