Selenium webdriver Selenium WebDriver-由于客户端不在,会话已终止

Selenium webdriver Selenium WebDriver-由于客户端不在,会话已终止,selenium-webdriver,selenium-grid,selenium-firefoxdriver,Selenium Webdriver,Selenium Grid,Selenium Firefoxdriver,我使用SeleniumWebDriver在网格模式下运行一套测试。当我运行所有的测试,如果它都通过了,我对测试套件没有任何问题 但是如果一个测试失败,比如说在一组200个测试中,如果测试121失败,那么所有剩余的测试都不会执行,我得到的响应如下 System.InvalidOperationException:会话[]已终止,因为所有测试的客户端已退出 任何关于这方面的建议都会很有帮助。谢谢 下面是stacktrace Result2 Name: AboutThem (Data Row 2)

我使用SeleniumWebDriver在网格模式下运行一套测试。当我运行所有的测试,如果它都通过了,我对测试套件没有任何问题

但是如果一个测试失败,比如说在一组200个测试中,如果测试121失败,那么所有剩余的测试都不会执行,我得到的响应如下 System.InvalidOperationException:会话[]已终止,因为所有测试的客户端已退出

任何关于这方面的建议都会很有帮助。谢谢

下面是stacktrace

Result2 Name:   AboutThem (Data Row 2)
Result2 Outcome:    Failed
Result2 Duration:   0:11:32.4810094
Result2 StackTrace: 
Server stack trace: 
at OpenQA.Selenium.Remote.RemoteWebDriver.UnpackAndThrowOnError(Response errorResponse)
at OpenQA.Selenium.Remote.RemoteWebDriver.Execute(String driverCommandToExecute, Dictionary`2 parameters)
at OpenQA.Selenium.Remote.RemoteWebDriver.FindElement(String mechanism, String value)
at OpenQA.Selenium.Remote.RemoteWebDriver.FindElementByXPath(String xpath)
at OpenQA.Selenium.By.<>c__DisplayClasse.<XPath>b__c(ISearchContext context)
at OpenQA.Selenium.By.FindElement(ISearchContext context)
at OpenQA.Selenium.Remote.RemoteWebDriver.FindElement(By by)
at WebElementFactory.GetWebElement(IWebDriver driver, String identifier) in C:\WebElementFactory.cs:line 36
at System.Runtime.Remoting.Messaging.Message.Dispatch(Object target)
at system.Runtime.Remoting.Messaging.StackBuilderSink.SyncProcessMessage(IMessage msg)
Exception rethrown at [0]: 
at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg)
at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type)
at Driver.AboutThem()
Result2 Message:    
Test method Driver.AboutThem threw exception: 
System.InvalidOperationException: Session [] was terminated due to CLIENT_GONE
Result2名称:关于它们(数据行2)
结果2结果:失败
结果2持续时间:0:11:32.4810094
结果2 StackTrace:
服务器堆栈跟踪:
在OpenQA.Selenium.Remote.RemoteWebDriver.UnpackantRownerError(响应错误响应)中
在OpenQA.Selenium.Remote.RemoteWebDriver.Execute(stringdrivercommandtoexecute,Dictionary`2参数)
在OpenQA.Selenium.Remote.RemoteWebDriver.FindElement(字符串机制,字符串值)
位于OpenQA.Selenium.Remote.RemoteWebDriver.FindElementByXPath(字符串xpath)
在OpenQA.Selenium.By.c_;u DisplayClasse.b_;c(ISearchContext上下文)中
在OpenQA.Selenium.By.FindElement(ISearchContext)上
位于OpenQA.Selenium.Remote.RemoteWebDriver.FindElement(By)
在C:\WebElementFactory.cs中的WebElementFactory.GetWebElement(IWebDriver驱动程序,字符串标识符):第36行
at System.Runtime.Remoting.Messaging.Message.Dispatch(对象目标)
在system.Runtime.Remoting.Messaging.StackBuilderSink.SyncProcessMessage(IMessage msg)中
在[0]处重试异常:
at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg,IMessage retMsg)
at System.Runtime.Remoting.proxy.RealProxy.PrivateInvoke(MessageData&msgData,Int32类型)
在Driver.AboutThem()处
结果2消息:
测试方法Driver.About抛出异常:
System.InvalidOperationException:会话[]已终止,因为客户端\u已离开

您在这里讲了几件事。1.如果您的一个测试失败,那么其余的测试将无法执行——为此,您需要显示代码的外观,以便有人能够帮助您。2.关于“客户离开”的问题,您是否在此处查看[1],看看这是否有帮助?[1]