I can debug but unable to execute my Selenium C# script
If i debug my code 开发者_如何学编程its running line by line successfully. but when i run without breakpoints it shows the following error and my script failed.
"Failed PaymentGateway ProjectFunctions Test method Project_Automation.Functions.PaymentGateway threw exception: Selenium.SeleniumException: ERROR: There was an unexpected Alert! [Sys.WebForms.PageRequestManagerServerErrorException: An unknown error occurred while processing the request on the server. The status code returned from the server was: 0]."
Browser shows no error in UI. but Error console shows "Error: setting a property that has only a getter"
It shows at the end of a single for loop. i am unable to execute rest of the loops
Sounds like the property evaluation in one of the debugger windows has a side effect. This happens sometimes, try to turn this setting off in VS to eliminate this:
Tools -> Options -> Debugging -> Enabled property evaluation and other implicit function calls
精彩评论