I have used Test studio for web applications, but I am now trying to automate tests for a hybrid mobile app.
Does Test Studio Mobile support data-driven testing for hyprid apps?
Hi,
document.getElementsByTagName('select')[6];target.dispatchEvent(evt);] failed! Please make sure the function exists and the call is using the correc
I updated test studio version yesterday and then started seeing this error in all places where drop down is when tests are ran.
Below is the error --
ExecuteCommand failed!InError set by the client. Client Error:System.InvalidOperationException: Javascript call [var eventObjJSON = 'null';var eventObj = JSON.parse(eventObjJSON);var eventType = "HTMLEvents";var eventName = "change";var evt = document.createEvent(eventType);if (!evt) throw "Error creating event";var altKey = false;var ctrlKey = false;var shiftKey = false;var metaKey = false;if (eventType == "HTMLEvents" || !eventObj) {evt.initEvent(eventName, true, true);}else {if (eventObj.modifiers & 0x01)altKey = true;if (eventObj.modifiers & 0x02)ctrlKey = true;if (eventObj.modifiers & 0x04)shiftKey = true;if (eventObj.modifiers & 0x08)metaKey = true;if (eventType == "MouseEvents") {var button = 0;if (eventObj.button & 1)button = 0;else if (eventObj.button & 2)button = 2;else if (eventObj.button & 4)button = 1;var relatedTarget;if (eventObj.relatedTarget)relatedTarget = eval(eventObj.relatedTarget);evt.initMouseEvent(eventName, true, true, window, 0, eventObj.screenX, eventObj.screenY,0, 0, ctrlKey, altKey, shiftKey, metaKey, button, relatedTarget);}else if (eventType == "KeyboardEvent") {var keyCode;var charCode;keyCode = eventObj.keyCode;if (eventName == "keypress") {charCode = eventObj.keyCode;}else {charCode = 0;}var keyNum = String.fromCharCode(parseInt(keyCode)).toUpperCase().charCodeAt(0);var keyIdentifier = "U+00" + keyNum.toString(16);evt.initKeyboardEvent(true, true, window,keyIdentifier,0, ctrlKey, altKey, shiftKey, metaKey);}}var target = document.getElementsByTagName('select')[6];target.dispatchEvent(evt);] failed! Please make sure the function exists and the call is using the correct prototype signature. Javascript error: [object Error] at ArtOfTest.InternetExplorer.IECommandProcessor.InvokeFunction(String functionCall, Boolean useEval, Boolean returnJson, IHTMLDocument2 doc) at ArtOfTest.InternetExplorer.IECommandProcessor.InvokeEvent(IHTMLElement target, BrowserCommand command) at ArtOfTest.InternetExplorer.IECommandProcessor.ProcessActionCommands(BrowserCommand request) at ArtOfTest.InternetExplorer.IECommandProcessor.ProcessCommandInternal(WebBrowserClass ieInstance, BrowserCommand request, IHTMLDocument2 document)BrowserCommand (Type:'Action',Info:'NotSet',Action:'InvokeEvent',Target:'ElementId (tagName: 'select',occurrenceIndex: '6')',Data:'onchange--@@--null',ClientId:'Client_c62ec753-e4e2-4ff5-af77-8fe0c44bee21',HasFrames:'False',FramesInfo:'',TargetFrameIndex:'2',InError:'True',Response:'System.InvalidOperationException: Javascript call [var eventObjJSON = 'null';var eventObj = JSON.parse(eventObjJSON);var eventType = "HTMLEvents";var eventName = "change";var evt = document.createEvent(eventType);if (!evt) throw "Error creating event";var altKey = false;var ctrlKey = false;var shiftKey = false;var metaKey = false;if (eventType == "HTMLEvents" || !eventObj) {evt.initEvent(eventName, true, true);}else {if (eventObj.modifiers & 0x01)altKey = true;if (eventObj.modifiers & 0x02)ctrlKey = true;if (eventObj.modifiers & 0x04)shiftKey = true;if (eventObj.modifiers & 0x08)metaKey = true;if (eventType == "MouseEvents") {var button = 0;if (eventObj.button & 1)button = 0;else if (eventObj.button & 2)button = 2;else if (eventObj.button & 4)button = 1;var relatedTarget;if (eventObj.relatedTarget)relatedTarget = eval(eventObj.relatedTarget);evt.initMouseEvent(eventName, true, true, window, 0, eventObj.screenX, eventObj.screenY,0, 0, ctrlKey, altKey, shiftKey, metaKey, button, relatedTarget);}else if (eventType == "KeyboardEvent") {var keyCode;var charCode;keyCode = eventObj.keyCode;if (eventName == "keypress") {charCode = eventObj.keyCode;}else {charCode = 0;}var keyNum = String.fromCharCode(parseInt(keyCode)).toUpperCase().charCodeAt(0);var keyIdentifier = "U+00" + keyNum.toString(16);evt.initKeyboardEvent(true, true, window,keyIdentifier,0, ctrlKey, altKey, shiftKey, metaKey);}}var target = document.getElementsByTagName('select')[6];target.dispatchEvent(evt);] failed! Please make sure the function exists and the call is using the correct prototype signature. Javascript error: [object Error] at ArtOfTest.InternetExplorer.IECommandProcessor.InvokeFunction(String functionCall, Boolean useEval, Boolean returnJson, IHTMLDocument2 doc) at ArtOfTest.InternetExplorer.IECommandProcessor.InvokeEvent(IHTMLElement target, BrowserCommand command) at ArtOfTest.InternetExplorer.IECommandProcessor.ProcessActionCommands(BrowserCommand request) at ArtOfTest.InternetExplorer.IECommandProcessor.ProcessCommandInternal(WebBrowserClass ieInstance, BrowserCommand request, IHTMLDocument2 document)')InnerException: none.InnerException:ArtOfTest.WebAii.Exceptions.ExecuteCommandException: ExecuteCommand failed!InError set by the client. Client Error:System.InvalidOperationException: Javascript call [var eventObjJSON = 'null';var eventObj = JSON.parse(eventObjJSON);var eventType = "HTMLEvents";var eventName = "change";var evt = document.createEvent(eventType);if (!evt) throw "Error creating event";var altKey = false;var ctrlKey = false;var shiftKey = false;var metaKey = false;if (eventType == "HTMLEvents" || !eventObj) {evt.initEvent(eventName, true, true);}else {if (eventObj.modifiers & 0x01)altKey = true;if (eventObj.modifiers & 0x02)ctrlKey = true;if (eventObj.modifiers & 0x04)shiftKey = true;if (eventObj.modifiers & 0x08)metaKey = true;if (eventType == "MouseEvents") {var button = 0;if (eventObj.button & 1)button = 0;else if (eventObj.button & 2)button = 2;else if (eventObj.button & 4)button = 1;var relatedTarget;if (eventObj.relatedTarget)relatedTarget = eval(eventObj.relatedTarget);evt.initMouseEvent(eventName, true, true, window, 0, eventObj.screenX, eventObj.screenY,0, 0, ctrlKey, altKey, shiftKey, metaKey, button, relatedTarget);}else if (eventType == "KeyboardEvent") {var keyCode;var charCode;keyCode = eventObj.keyCode;if (eventName == "keypress") {charCode = eventObj.keyCode;}else {charCode = 0;}var keyNum = String.fromCharCode(parseInt(keyCode)).toUpperCase().charCodeAt(0);var keyIdentifier = "U+00" + keyNum.toString(16);evt.initKeyboardEvent(true, true, window,keyIdentifier,0, ctrlKey, altKey, shiftKey, metaKey);}}var target = document.getElementsByTagName('select')[6];target.dispatchEvent(evt);] failed! Please make sure the function exists and the call is using the correct prototype signature. Javascript error: [object Error] at ArtOfTest.InternetExplorer.IECommandProcessor.InvokeFunction(String functionCall, Boolean useEval, Boolean returnJson, IHTMLDocument2 doc) at ArtOfTest.InternetExplorer.IECommandProcessor.InvokeEvent(IHTMLElement target, BrowserCommand command) at ArtOfTest.InternetExplorer.IECommandProcessor.ProcessActionCommands(BrowserCommand request) at ArtOfTest.InternetExplorer.IECommandProcessor.ProcessCommandInternal(WebBrowserClass ieInstance, BrowserCommand request, IHTMLDocument2 document)BrowserCommand (Type:'Action',Info:'NotSet',Action:'InvokeEvent',Target:'ElementId (tagName: 'select',occurrenceIndex: '6')',Data:'onchange--@@--null',ClientId:'Client_c62ec753-e4e2-4ff5-af77-8fe0c44bee21',HasFrames:'False',FramesInfo:'',TargetFrameIndex:'2',InError:'True',Response:'System.InvalidOperationException: Javascript call [var eventObjJSON = 'null';var eventObj = JSON.parse(eventObjJSON);var eventType = "HTMLEvents";var eventName = "change";var evt = document.createEvent(eventType);if (!evt) throw "Error creating event";var altKey = false;var ctrlKey = false;var shiftKey = false;var metaKey = false;if (eventType == "HTMLEvents" || !eventObj) {evt.initEvent(eventName, true, true);}else {if (eventObj.modifiers & 0x01)altKey = true;if (eventObj.modifiers & 0x02)ctrlKey = true;if (eventObj.modifiers & 0x04)shiftKey = true;if (eventObj.modifiers & 0x08)metaKey = true;if (eventType == "MouseEvents") {var button = 0;if (eventObj.button & 1)button = 0;else if (eventObj.button & 2)button = 2;else if (eventObj.button & 4)button = 1;var relatedTarget;if (eventObj.relatedTarget)relatedTarget = eval(eventObj.relatedTarget);evt.initMouseEvent(eventName, true, true, window, 0, eventObj.screenX, eventObj.screenY,0, 0, ctrlKey, altKey, shiftKey, metaKey, button, relatedTarget);}else if (eventType == "KeyboardEvent") {var keyCode;var charCode;keyCode = eventObj.keyCode;if (eventName == "keypress") {charCode = eventObj.keyCode;}else {charCode = 0;}var keyNum = String.fromCharCode(parseInt(keyCode)).toUpperCase().charCodeAt(0);var keyIdentifier = "U+00" + keyNum.toString(16);evt.initKeyboardEvent(true, true, window,keyIdentifier,0, ctrlKey, altKey, shiftKey, metaKey);}}var target = document.getElementsByTagName('select')[6];target.dispatchEvent(evt);] failed! Please make sure the function exists and the call is using the correct prototype signature. Javascript error: [object Error] at ArtOfTest.InternetExplorer.IECommandProcessor.InvokeFunction(String functionCall, Boolean useEval, Boolean returnJson, IHTMLDocument2 doc) at ArtOfTest.InternetExplorer.IECommandProcessor.InvokeEvent(IHTMLElement target, BrowserCommand command) at ArtOfTest.InternetExplorer.IECommandProcessor.ProcessActionCommands(BrowserCommand request) at ArtOfTest.InternetExplorer.IECommandProcessor.ProcessCommandInternal(WebBrowserClass ieInstance, BrowserCommand request, IHTMLDocument2 document)')InnerException: none. at ArtOfTest.WebAii.Core.Browser.ExecuteCommandInternal(BrowserCommand request) at ArtOfTest.WebAii.Core.Browser.ExecuteCommand(BrowserCommand request, Boolean performDomRefresh, Boolean waitUntilReady) at ArtOfTest.WebAii.Core.Browser.ExecuteCommand(BrowserCommand request) at ArtOfTest.WebAii.Core.Actions.InvokeEvent(Element targetElement, ScriptEventType eventType) at ArtOfTest.WebAii.Controls.HtmlControls.HtmlControl.InvokeEvent(ScriptEventType eventType) at ArtOfTest.WebAii.Controls.HtmlControls.HtmlSelect.InvokeOnChange(Boolean initEvent) at ArtOfTest.WebAii.Design.IntrinsicTranslators.Descriptors.SelectDropDownActionDescriptor.Execute(Browser browser) at ArtOfTest.WebAii.Design.Extensibility.HtmlActionDescriptor.Execute(IAutomationHost autoHost) at ArtOfTest.WebAii.Design.Execution.ExecutionEngine.ExecuteStep(Int32 order)
Hello,
please, take a look at https://harvesthq.github.io/chosen/ .
- there's a example dropdown element under: "Standard Select" -> "Into This" (a select for countries on the right side)
Can anyone tell my, how i set this element to "Germany" without using a Desktopcommand Mouse Leftclick
Thanks
André
The first congrats for really great job on product. Awesome. Love it. Its great tool for developers and QA.
One thing constantly pops up in between developers and QA how to reproduce error for specific platform as its required new setup (Azure or Amazon storage).
Would it possible to add new step (Http Request, Verification and ect)? The step would be just text notes and would use Telerik Edit control with minimal features.
Essentially its readme block, where all information stored for devs and QA. It would be great help, as wiki pages or word docs quick getting out of sync and hard to maintain. Keeping everything together big bonus for development as requirements changes quickly in agile land.
If the text nodes could store images as base64 what would be great.
Sincerely J.B
Hi,
I am testing a WCF Service using Test Studio, the service(POST) accepts only JSON body.
I have selected boy format as raw and type as JSON, but I am getting the following error
The incoming message has an unexpected message format 'Raw'
Please help
I’m testing a webpage that enforces agreeing to the site's Terms and Conditions before proceeding on. This page uses AngularJS to implement a form where the user must scroll to the bottom before the “I agree” button gets enabled. The only way to access the bottom of the T&C text (enabling the button) is via scrollbar.
See attached file for details
Hi,
Can anyone help me how I can retrieve a label text or dropdown list selected text and save it on excel file using vb code.
I tried from calling the element but still nothing.
<CodedStep("Store Data in Excel")> _
Public Sub Transfers_Between_CodedStep()
Dim dataSourcePath As String = Me.ExecutionContext.DeploymentDirectory + "\Data\domainResults.xlsx" 'this method is calling a link from an excel file and pass it on url path to load it
Dim myPath As String = "C:\Users\Charitos\Documents\TransferInputs.xlsx"
If Not System.IO.File.Exists(myPath) Then
System.IO.File.Copy(dataSourcePath, myPath)
End If
Dim excelApp As New Microsoft.Office.Interop.Excel.Application()
Dim workbook As Microsoft.Office.Interop.Excel.Workbook = excelApp.Workbooks.Open(myPath)
System.Threading.Thread.Sleep(1000)
ActiveBrowser.RefreshDomTree()
excelApp.Cells(Data.IterationIndex + 2, 1) = Pages.AlHilalEbankingSolution1.TransactionSpan.AssertContent() //This is where I want to call the element or some other way from the webpage that is still open to retrieve the text and store it on excel.
excelApp.Visible = True
excelApp.ActiveWorkbook.Save()
workbook.Close(False, Type.Missing, Type.Missing)
excelApp.Workbooks.Close()
System.Runtime.InteropServices.Marshal.ReleaseComObject(workbook)
excelApp.Quit()
GC.Collect()
System.Runtime.InteropServices.Marshal.ReleaseComObject(excelApp)
End Sub
End Class