Hello!!!
Im new working with Selenium IDE. And im writing some User-Extensions for one WebPage testing
My problem is that I have the next Local XML file in "x"-path:
(Login.xml)
<?xml version=”1.0??>
<Login>
<URL>xxx</URL>
<User>yyy</User>
<Password>zzz</Password>
</Login>
These are some Values for the Login of the WepPage that Im testing. I need a Solution to read this xml.file values and use them later using the "user-extensions.js".
Can somebody help please.
Thanks
chaco
The datadriven extension I uploaded this week does exactly that, it may be of use to you.
Hi, Sorry to bother you again.
Im having the next message when I try to run your script
____
[error] Unexpected Exception: message -> Test data couldn't be loaded or test data was empty., fileName -> chrome://selenium-ide/content/tools.js -> file:///C:/Documents%20and%20Settings/comaces/My%20Documents/boe/ILevo/Tools/JS-Extensions/user-extensions.js, lineNumber -> 488, stack -> Error("Test data couldn't be loaded or test data was empty.")@:0 ("file://c:/googlesearches.xml")@chrome://selenium-ide/content/tools.js -> file:///C:/Documents%20and%20Settings/comaces/My%20Documents/boe/ILevo/Tools/JS-Extensions/user-extensions.js:488 ("file://c:/googlesearches.xml","")@chrome://selenium-ide/content/tools.js -> file:///C:/Documents%20and%20Settings/comaces/My%20Documents/boe/ILevo/Tools/JS-Extensions/user-extensions.js:526 ("file://c:/googlesearches.xml","")@chrome://selenium-ide/content/selenium/scripts/htmlutils.js:60 ([object Object],[object Object])@chrome://selenium-ide/content/selenium/scripts/selenium-commandhandlers.js:309 ()@chrome://selenium-ide/content/selenium/scripts/selenium-executionloop.js:112 (10)@chrome://selenium-ide/content/selenium/scripts/selenium-executionloop.js:78 (10)@chrome://selenium-ide/content/selenium/scripts/htmlutils.js:60 , name -> Error
_____
Im using your script and the flowcontrol Script. I tried to run exactly your example but it doesnt work. (Copy command by command and added the googlesearches.xml to the c:/ drive). Am I forgeting something else or should I use some other special Settings?
Hi I think there is a problem in this part of the Script
---------------------------------------------------------------------------------------
try {
this.xmlDoc.async = false;
//There is a problem in the next line
this.xmlDoc.load(xmlloc);
this.index = 0;
this.testdata = this.xmlDoc.getElementsByTagName("test");
}
_________________________________________
The Value for "xmlloc" is "file://c:/googlesearches.xml".
Do you have a Solution??
Thanks
Hi,
Yes there's a bug in FF3 (or a new security restriction)
Replace the line
this.xmlDoc.load(xmlloc);
by:
var xhr_object = null;
xhr_object = new XMLHttpRequest();
xhr_object.open("GET", xmlloc, false);
xhr_object.send(null);
this.xmlDoc=xhr_object.responseXML;
it worked fine for me
Nicolas
Hi,
I've looked at all the comments above and have managed to resolve the problems as posted above.
However I'm receiving the following?
[error] Unexpected Exception: message -> No while statements found., fileName -> chrome://selenium-ide/content/tools.js -> file:///C:/goto.js, lineNumber -> 249, stack -> Error("No while statements found.")@:0 gotoWhile("","")@chrome://selenium-ide/content/tools.js -> file:///C:/goto.js:249 ("","")@chrome://selenium-ide/content/selenium/scripts/htmlutils.js:60 ([object Object],[object Object])@chrome://selenium-ide/content/selenium/scripts/selenium-commandhandlers.js:309 ()@chrome://selenium-ide/content/selenium/scripts/selenium-executionloop.js:112 (109)@chrome://selenium-ide/content/selenium/scripts/selenium-executionloop.js:78 (109)@chrome://selenium-ide/content/selenium/scripts/htmlutils.js:60 , name -> Error
Any help will be greatly appreciated.
Thanks.
I am also having issues with the extension as well, this is the error I'm getting:
Failed to load user-extensions.js!
files=C:\\tests\\user-extensions.js, C:\tests\goto_sel08.js+, C:\tests\datadriven.js
lineNumber=231
error=ReferenceError: HtmlRunnerTestLoop is not defined
Hi all.
I've uploaded an update to this extension and its documentation which I hope will resolve the issues that some of you have had.
Constructive feedback is appreciated, as always.
With thanks,
Jonathan McBrien
