gpt4 book ai didi

selenium-webdriver - reportTestCaseResult() 给出 teSTLink.api.java.client.TestLinkAPIException

转载 作者:行者123 更新时间:2023-12-03 10:28:12 24 4
gpt4 key购买 nike

我正在尝试将 selenium 与 TeSTLink 测试管理工具集成,我已经使用 wampserver 在我的本地机器上成功安装了 teSTLink。请引用我在以下谷歌文档链接中编写的 selenium 脚本:https://docs.google.com/document/d/1jyUBqJ9cx5496GiCTC5ktuXSXAYfhHmr7HLr6liTpbQ/edit

当我使用 Testng 运行脚本时出现以下异常:

[Fatal Error] :3:6: The processing instruction target matching "[xX][mM][lL]" is not allowed.
[Fatal Error] :3:6: The processing instruction target matching "[xX][mM][lL]" is not allowed.
[Fatal Error] :3:6: The processing instruction target matching "[xX][mM][lL]" is not allowed.
[Fatal Error] :3:6: The processing instruction target matching "[xX][mM][lL]" is not allowed.
FAILED: f
testlink.api.java.client.TestLinkAPIException: The call to the xml-rpc client failed.
at testlink.api.java.client.TestLinkAPIClient.executeXmlRpcMethod(TestLinkAPIClient.java:1266)
at testlink.api.java.client.TestLinkAPIClient.execXmlRpcMethodWithCache(TestLinkAPIClient.java:1195)
at testlink.api.java.client.TestLinkAPIClient.getProjects(TestLinkAPIClient.java:726)
at testlink.api.java.client.TestLinkAPIHelper.getProjectInfo(TestLinkAPIHelper.java:64)
at testlink.api.java.client.TestLinkAPIHelper.getProjectID(TestLinkAPIHelper.java:48)
at testlink.api.java.client.TestLinkAPIClient.reportTestCaseResult(TestLinkAPIClient.java:184)
at Pack3.ResultTestlink.reportTestCaseResult1(ResultTestlink.java:11)
at Pack3.TestlinkExcecution.f(TestlinkExcecution.java:62)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.testng.internal.MethodInvocationHelper.invokeMethod(MethodInvocationHelper.java:80)
at org.testng.internal.Invoker.invokeMethod(Invoker.java:714)
at org.testng.internal.Invoker.invokeTestMethod(Invoker.java:901)
at org.testng.internal.Invoker.invokeTestMethods(Invoker.java:1231)
at org.testng.internal.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:128)
at org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:111)
at org.testng.TestRunner.privateRun(TestRunner.java:767)
at org.testng.TestRunner.run(TestRunner.java:617)
at org.testng.SuiteRunner.runTest(SuiteRunner.java:334)
at org.testng.SuiteRunner.runSequentially(SuiteRunner.java:329)
at org.testng.SuiteRunner.privateRun(SuiteRunner.java:291)
at org.testng.SuiteRunner.run(SuiteRunner.java:240)
at org.testng.SuiteRunnerWorker.runSuite(SuiteRunnerWorker.java:52)
at org.testng.SuiteRunnerWorker.run(SuiteRunnerWorker.java:86)
at org.testng.TestNG.runSuitesSequentially(TestNG.java:1203)
at org.testng.TestNG.runSuitesLocally(TestNG.java:1128)
at org.testng.TestNG.run(TestNG.java:1036)
at org.testng.remote.RemoteTestNG.run(RemoteTestNG.java:111)
at org.testng.remote.RemoteTestNG.initAndRun(RemoteTestNG.java:204)
at org.testng.remote.RemoteTestNG.main(RemoteTestNG.java:175)
Caused by: org.apache.xmlrpc.client.XmlRpcClientException: Failed to parse servers response: The processing instruction target matching "[xX][mM][lL]" is not allowed.
at org.apache.xmlrpc.client.XmlRpcStreamTransport.readResponse(XmlRpcStreamTransport.java:177)
at org.apache.xmlrpc.client.XmlRpcStreamTransport.sendRequest(XmlRpcStreamTransport.java:145)
at org.apache.xmlrpc.client.XmlRpcHttpTransport.sendRequest(XmlRpcHttpTransport.java:94)
at org.apache.xmlrpc.client.XmlRpcSunHttpTransport.sendRequest(XmlRpcSunHttpTransport.java:44)
at org.apache.xmlrpc.client.XmlRpcClientWorker.execute(XmlRpcClientWorker.java:53)
at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:166)
at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:157)
at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:146)
at testlink.api.java.client.TestLinkAPIClient.executeXmlRpcMethod(TestLinkAPIClient.java:1232)
... 31 more
Caused by: org.xml.sax.SAXParseException; lineNumber: 3; columnNumber: 6; The processing instruction target matching "[xX][mM][lL]" is not allowed.
at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
at org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown Source)
at org.apache.xmlrpc.client.XmlRpcStreamTransport.readResponse(XmlRpcStreamTransport.java:175)
... 39 more

请让我知道我在这里做错了什么。

最佳答案

通过编辑位于 TestLink 根文件夹中的 config.inc 启用 XML-RPC

$tlCfg->api->enabled = TRUE;
$g_attachments->order_by = " ORDER BY id ASC ";

关于selenium-webdriver - reportTestCaseResult() 给出 teSTLink.api.java.client.TestLinkAPIException,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/15135345/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com