TeskLink1.9.8bug—导入需求类testCase报错

TestLink导入需求类测试用例的时候,报下面错误:
前台页面报的错误

#0 database->exec_query() called at [C:\xampp\htdocs\testlink\lib\functions\requirement_mgr.class.php:1000]
#1 requirement_mgr->assign_to_tcase() called at [C:\xampp\htdocs\testlink\lib\testcases\tcImport.php:668]
#2 processRequirements() called at [C:\xampp\htdocs\testlink\lib\testcases\tcImport.php:453]
#3 saveImportedTCData() called at [C:\xampp\htdocs\testlink\lib\testcases\tcImport.php:938]
#4 importTestSuitesFromSimpleXML() called at [C:\xampp\htdocs\testlink\lib\testcases\tcImport.php:945]
#5 importTestSuitesFromSimpleXML() called at [C:\xampp\htdocs\testlink\lib\testcases\tcImport.php:945]
#6 importTestSuitesFromSimpleXML() called at [C:\xampp\htdocs\testlink\lib\testcases\tcImport.php:169]
#7 importTestCaseDataFromXML() called at [C:\xampp\htdocs\testlink\lib\testcases\tcImport.php:76]

后台日志报的错误:

Query failed: errorcode[1064]
errormsg:You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ''2013-10-21 10:07:18')' at line 1
[13/Oct/21 08:07:18][AUDIT][ftp6i7qei5rdhl2aruqrspg3g1][GUI]
Requirement with title '编号XQ3' was assigned to the Test Case '需求NO-2编号XQ2--测试第三环节'



报错是由于插入需求覆盖表req_coverage的SQL有问题,其中author_id传入的字符串

修改程序:
testlink\lib\testcases\tcImport.php 668行,
$reqMgr->assign_to_tcase($cachedReqSpec[$value[ 'req_spec_title']]['req' ][$value['doc_id']],$tcaseId,1);
加入传入 author_id 字段,由于项目的需求,默认写成 1 ,为admin用户
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值