Permalink
Browse files

Updating to the latest version of selenium Core.

git-svn-id: https://svn.openqa.org/svn/selenium-on-rails/selenium-on-rails@128 9274398c-e119-0410-8437-aa71ef7847aa
  • Loading branch information...
1 parent 35648d7 commit fb1727fdc7e6e524804d92d248d082342f6af332 eric@8thlight.com committed Mar 7, 2009
Showing with 14,051 additions and 6,149 deletions.
  1. +53 −1 .gitignore
  2. +0 −1 selenium-core/Blank.html
  3. +22 −21 selenium-core/RemoteRunner.html
  4. +42 −7 selenium-core/SeleniumLog.html
  5. +23 −1 selenium-core/TestPrompt.html
  6. +15 −13 selenium-core/TestRunner.hta
  7. +15 −13 selenium-core/TestRunner.html
  8. 0 selenium-core/domviewer/selenium-domviewer.js
  9. +412 −84 selenium-core/iedoc-core.xml
  10. +516 −84 selenium-core/iedoc.xml
  11. 0 selenium-core/lib/cssQuery/cssQuery-p.js
  12. 0 selenium-core/lib/cssQuery/src/cssQuery-level2.js
  13. 0 selenium-core/lib/cssQuery/src/cssQuery-level3.js
  14. 0 selenium-core/lib/cssQuery/src/cssQuery-standard.js
  15. 0 selenium-core/lib/cssQuery/src/cssQuery.js
  16. +2 −2 selenium-core/lib/prototype.js
  17. 0 selenium-core/lib/scriptaculous/builder.js
  18. 0 selenium-core/lib/scriptaculous/controls.js
  19. 0 selenium-core/lib/scriptaculous/dragdrop.js
  20. 0 selenium-core/lib/scriptaculous/effects.js
  21. 0 selenium-core/lib/scriptaculous/scriptaculous.js
  22. 0 selenium-core/lib/scriptaculous/slider.js
  23. 0 selenium-core/lib/scriptaculous/unittest.js
  24. +91 −0 selenium-core/lib/snapsie.js
  25. 0 selenium-core/scripts/find_matching_child.js
  26. +816 −42 selenium-core/scripts/htmlutils.js
  27. +72 −79 selenium-core/scripts/injection.html
  28. +0 −7 selenium-core/scripts/injection_iframe.html
  29. +0 −70 selenium-core/scripts/js2html.js
  30. +0 −175 selenium-core/scripts/narcissus-defs.js
  31. +0 −1,054 selenium-core/scripts/narcissus-exec.js
  32. +0 −1,003 selenium-core/scripts/narcissus-parse.js
  33. +0 −63 selenium-core/scripts/se2html.js
  34. +1,033 −178 selenium-core/scripts/selenium-api.js
  35. +574 −220 selenium-core/scripts/selenium-browserbot.js
  36. +12 −1 selenium-core/scripts/selenium-browserdetect.js
  37. +2 −0 selenium-core/scripts/selenium-commandhandlers.js
  38. +3 −5 selenium-core/scripts/selenium-executionloop.js
  39. +36 −27 selenium-core/scripts/selenium-logging.js
  40. +295 −66 selenium-core/scripts/selenium-remoterunner.js
  41. +145 −64 selenium-core/scripts/selenium-testrunner.js
  42. +2 −2 selenium-core/scripts/selenium-version.js
  43. +803 −0 selenium-core/scripts/ui-doc.html
  44. +1,537 −0 selenium-core/scripts/ui-element.js
  45. +979 −0 selenium-core/scripts/ui-map-sample.js
  46. +3 −0 selenium-core/scripts/user-extensions.js
  47. 0 selenium-core/scripts/xmlextras.js
  48. BIN selenium-core/selenium-logo.png
  49. +18 −1 selenium-core/selenium.css
  50. +566 −428 selenium-core/xpath/dom.js
  51. +2,816 −0 selenium-core/xpath/javascript-xpath-0.1.11.js
  52. +0 −255 selenium-core/xpath/misc.js
  53. +549 −0 selenium-core/xpath/util.js
  54. +149 −0 selenium-core/xpath/xmltoken.js
  55. +2,450 −2,182 selenium-core/xpath/xpath.js
View
@@ -3,4 +3,56 @@ gems
test_data/html.html
test_data/html.rsel
test_data/html.sel
-coverage/*
+coverage/*
+
++== VERSION 40[http://github.com/jtrupiano/selenium-on-rails]
+0
++
+0
++* Jan 20, 2009 (inauguration day, baby!)
+0
++
+0
++* [jtrupiano] updated the CHANGELOG to include all of my changes to my branch from the last couple of months.
+0
++
+0
++* [jkrall] applied the following commits from jkrall (mostly related to updating prototype and scriptaculous versions): [http://github.com/jtrupiano/selenium-on-rails/commit/2084c9ad1740deb920483025e65db58a7cf9c573], [http://github.com/jtrupiano/selenium-on-rails/commit/d07d932437b4340db34b85d75e6f9527186b7f69], [http://github.com/jtrupiano/selenium-on-rails/commit/6738790308cb8531744513107b1a37ad26734c63]
+0
++
+0
++* [jtrupiano] Tweaks to make my recent changes environment-independent. Also now allowing password-protected access to the database (to backup and restore the database in between test cases). [http://github.com/jtrupiano/selenium-on-rails/commit/6ec035a183adc9f1bb40a04fba9104f211bc4647]
+0
++
+0
++
+0
++== VERSION 39[http://github.com/jtrupiano/selenium-on-rails/commit/47653c3bdb2f5ab434697ed9a5d50e0bf3759fbd]
+0
++
+0
++* Dec 12. 2008
+0
++
+0
++* [jtrupiano] Tweaked the javascript teardownServer() function to not use show()/hide() (from prototype). Unsure why this blows up in IE. On this note, the label itself notifying the user that the teardown is in progress does not properly display for IE. [http://github.com/jtrupiano/selenium-on-rails/commit/47653c3bdb2f5ab434697ed9a5d50e0bf3759fbd]
+0
++
+0
++* [jtrupiano] Added in support for a server-side teardown. Makes a synchronous call to /selenium/setup, which maps to my previously committed action augmentation to the selenium_controller. This server-side teardown is now called after each test is completed (on failure or success), providing us an easy mechanism for restoring the state of server-side assets (db/filesystem/etc) without having to use fixtures. [http://github.com/jtrupiano/selenium-on-rails/commit/6b03f347c584a65c5787127e8930487f1e7b1e13]
+0
++
+0
++* [jtrupiano] Added in a rakefile that exposes tasks for simulating a transactional db across selenium tests (essentially dumps a mysqldump in tmp/ and re-uses). [http://github.com/jtrupiano/selenium-on-rails/commit/2e1fee675b9c89f4a093fd0c0ae8d73943dc3f89]
+0
++
+0
++* [jtrupiano] Added a route to match /selenium/setup/:action to invoke a controller (selenium_setup_controller) that is expected to be found in the rails app itself. Changed some of the language describing the :keep_db querystring parameter that replaced the fixture/db-specific params from the original implementation. [http://github.com/jtrupiano/selenium-on-rails/commit/4b40d05e66524bab8949a9b62c47ab1673bd06d9]
+0
++
+0
++* [jtrupiano] Replaced references to fixtures w/ StoryHelper-based transactional behavior (currently only works with mysql) [http://github.com/jtrupiano/selenium-on-rails/commit/290d3a1da54a43f162551de8c5dece26de9a7d66]
+0
++
+0
++
View
@@ -3,6 +3,5 @@
<meta content="text/html; charset=ISO-8859-1" http-equiv="content-type">
</head>
<body>
- <h3>selenium-rc initial page</h3>
</body>
</html>
@@ -19,12 +19,14 @@
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="content-type">
-<title>Selenium Functional Test Runner</title>
+<title>Selenium Remote Control</title>
<link rel="stylesheet" type="text/css" href="selenium.css" />
-<script language="JavaScript" type="text/javascript" src="jsunit/app/jsUnitCore.js"></script>
<script type="text/javascript" src="scripts/xmlextras.js"></script>
<script language="JavaScript" type="text/javascript" src="lib/prototype.js"></script>
+<script language="JavaScript" type="text/javascript" src="lib/cssQuery/cssQuery-p.js"></script>
+<script language="JavaScript" type="text/javascript" src="lib/snapsie.js"></script>
<script language="JavaScript" type="text/javascript" src="scripts/htmlutils.js"></script>
+<script language="JavaScript" type="text/javascript" src="scripts/ui-element.js"></script>
<script language="JavaScript" type="text/javascript" src="scripts/selenium-browserdetect.js"></script>
<script language="JavaScript" type="text/javascript" src="scripts/selenium-browserbot.js"></script>
<script language="JavaScript" type="text/javascript" src="scripts/find_matching_child.js"></script>
@@ -34,13 +36,14 @@
<script language="JavaScript" type="text/javascript" src="scripts/selenium-remoterunner.js"></script>
<script language="JavaScript" type="text/javascript" src="scripts/selenium-logging.js"></script>
<script language="JavaScript" type="text/javascript" src="scripts/selenium-version.js"></script>
-<script language="JavaScript" type="text/javascript" src="xpath/misc.js"></script>
+<script language="JavaScript" type="text/javascript" src="xpath/util.js"></script>
+<script language="JavaScript" type="text/javascript" src="xpath/xmltoken.js"></script>
<script language="JavaScript" type="text/javascript" src="xpath/dom.js"></script>
<script language="JavaScript" type="text/javascript" src="xpath/xpath.js"></script>
<script language="JavaScript" type="text/javascript" src="scripts/user-extensions.js"></script>
<script language="JavaScript" type="text/javascript">
function openDomViewer() {
- var autFrame = document.getElementById('myiframe');
+ var autFrame = document.getElementById('selenium_myiframe');
var autFrameDocument = getIframeDocument(autFrame);
var domViewer = window.open(getDocumentBase(document) + 'domviewer/domviewer.html');
domViewer.rootDocument = autFrameDocument;
@@ -58,29 +61,25 @@
<body onLoad="setTimeout(function(){runSeleniumTest();},1000)" onUnload="cleanUp()">
-<table border="1" style="height: 100%;">
+<table border="1" style="height: 100%; width: 100%;">
<tr>
- <td width="50%" height="30%">
+ <td width="50%">
<table>
<tr>
- <td>
- <img src="selenium-logo.png">
- </td>
- <td>
- <h1><a href="http://selenium.thoughtworks.com" >Selenium</a> Functional Testing for Web Apps</h1>
- Open Source From <a href="http://www.thoughtworks.com">ThoughtWorks, Inc</a> and Friends
+ <td class="remoterunner">
+ <h4><a href="http://selenium.openqa.org">Selenium</a> Functional Testing for Web Apps</h4>
+ Open Source From <a href="http://selenium.openqa.org/thoughtworks-and-friends.html">ThoughtWorks and Friends</a>
<form action="">
- <br/>Slow Mode:<INPUT TYPE="CHECKBOX" NAME="FASTMODE" VALUE="YES" onmouseup="slowClicked()">
-
+ <br/>
+ <iframe id="seleniumLoggingFrame" name="seleniumLoggingFrame" src="Blank.html" style="border: 0; height: 0; width: 0; "></iframe>
<fieldset>
- <legend>Tools</legend>
-
<button type="button" id="domViewer1" onclick="openDomViewer();">
View DOM
</button>
<button type="button" onclick="LOG.show();">
Show Log
</button>
+ <label><INPUT TYPE="CHECKBOX" NAME="FASTMODE" VALUE="YES" onmouseup="slowClicked()"> Slow Mode</label>
</fieldset>
</form>
@@ -92,14 +91,16 @@
<label id="context" name="context"></label>
</form>
</td>
- <td width="50%" height="30%">
- <b>Last Four Test Commands:</b><br/>
- <div id="commandList"></div>
+ <td width="50%" class="remoterunner">
+ <h4>Command History:</h4>
+ <form name="commands">
+ <textarea style="overflow:auto; height:8em; width:100%" wrap="off" id="commandList"></textarea>
+ </form>
</td>
</tr>
<tr>
- <td colspan="2" height="70%">
- <iframe name="myiframe" id="myiframe" src="" height="100%" width="100%"></iframe>
+ <td colspan="2" height="100%">
+ <iframe name="selenium_myiframe" id="selenium_myiframe" src="Blank.html" height="100%" width="100%"></iframe>
</td>
</tr>
</table>
@@ -3,11 +3,42 @@
<head>
<title>Selenium Log Console</title>
<link id="cssLink" rel="stylesheet" href="selenium.css" />
+<script src="scripts/htmlutils.js"></script>
+<script language="JavaScript">
-</head>
-<body id="logging-console">
+var disabled = true;
-<script language="JavaScript">
+function logOnLoad() {
+ var urlConfig = new URLConfiguration();
+ urlConfig.queryString = window.location.search.substr(1);
+ var startingThreshold = urlConfig._getQueryParameter("startingThreshold");
+ setThresholdLevel(startingThreshold);
+ var buttons = document.getElementsByTagName("input");
+ for (var i = 0; i < buttons.length; i++) {
+ addChangeListener(buttons[i]);
+ }
+}
+
+function enableButtons() {
+ var buttons = document.getElementsByTagName("input");
+ for (var i = 0; i < buttons.length; i++) {
+ buttons[i].disabled = false;
+ disabled = false;
+ }
+}
+
+function callBack() {}
+
+function changeHandler() {
+ callBack(getThresholdLevel());
+}
+
+function addChangeListener(element) {
+ if (window.addEventListener && !window.opera)
+ element.addEventListener("click", changeHandler, true);
+ else if (window.attachEvent)
+ element.attachEvent("onclick", changeHandler);
+}
var logLevels = {
debug: 0,
@@ -53,16 +84,20 @@
}
</script>
+</head>
+<body id="logging-console" onload="logOnLoad();">
+
+
<div id="banner">
<form id="logLevelChooser">
- <input id="level-error" type="radio" name="level"
+ <input id="level-error" type="radio" name="level" disabled='true'
value="error" /><label for="level-error">Error</label>
- <input id="level-warn" type="radio" name="level"
+ <input id="level-warn" type="radio" name="level" disabled='true'
value="warn" /><label for="level-warn">Warn</label>
- <input id="level-info" type="radio" name="level"
+ <input id="level-info" type="radio" name="level" disabled='true'
value="info" /><label for="level-info">Info</label>
- <input id="level-debug" type="radio" name="level" checked="yes"
+ <input id="level-debug" type="radio" name="level" checked="yes" disabled='true'
value="debug" /><label for="level-debug">Debug</label>
</form>
<h1>Selenium Log Console</h1>
@@ -20,12 +20,19 @@
http-equiv="content-type">
<title>Select a Test Suite</title>
<script language="JavaScript" type="text/javascript" src="scripts/selenium-browserdetect.js"></script>
+ <script language="JavaScript" type="text/javascript" src="scripts/xmlextras.js"></script>
<script>
function load() {
if (browserVersion.isHTA) {
document.getElementById("save-div").style.display = "inline";
}
+ if (/thisIsSeleniumServer/.test(window.location.search)) {
+ document.getElementById("slowResources-div").style.display = "inline";
+ if (browserVersion.isHTA || browserVersion.isChrome) {
+ document.getElementById("test").value = "http://localhost:4444/selenium-server/tests/TestSuite.html";
+ }
+ }
}
function autoCheck() {
@@ -38,6 +45,15 @@
}
}
+ function slowCheck() {
+ var slowResourcesCheckbox = document.getElementById("slowResources");
+ var slowResources = slowResourcesCheckbox.checked ? true : false;
+ var xhr = XmlHttp.create();
+ var driverUrl = "http://localhost:4444/selenium-server/driver/?cmd=slowResources&1=" + slowResources;
+ xhr.open("GET", driverUrl, true);
+ xhr.send(null);
+ }
+
function saveCheck() {
var results = document.getElementById("results");
var check = document.getElementById("save").checked;
@@ -51,7 +67,7 @@
}
function go() {
- if (!browserVersion.isHTA) return true;
+ if (!browserVersion.isHTA && !browserVersion.isChrome) return true;
var inputs = document.getElementsByTagName("input");
var queryString = "";
for (var i = 0; i < inputs.length; i++) {
@@ -94,6 +110,12 @@
<p>
+ <div id="slowResources-div" style="display: none">
+ <p>
+ <input id="slowResources" type="checkbox" name="slowResources" onclick="slowCheck();" /> <label for="slowResources">Slow down web server</label>
+ </p>
+ </div>
+
<p>
<input id="auto" type="checkbox" name="auto" onclick="autoCheck();"/> <label for="auto">Run
automatically</label>
@@ -26,13 +26,13 @@ to work-around a bug in IE on Win2K whereby the HTA application doesn't function
<title>Selenium Functional Test Runner</title>
<link rel="stylesheet" type="text/css" href="selenium.css"/>
- <script type="text/javascript" src="scripts/narcissus-defs.js"></script>
- <script type="text/javascript" src="scripts/narcissus-parse.js"></script>
- <script type="text/javascript" src="scripts/narcissus-exec.js"></script>
+ <script type="text/javascript" src="scripts/xmlextras.js"></script>
<script language="JavaScript" type="text/javascript" src="lib/prototype.js"></script>
+ <script language="JavaScript" type="text/javascript" src="lib/cssQuery/cssQuery-p.js"></script>
+ <script language="JavaScript" type="text/javascript" src="lib/snapsie.js"></script>
<script language="JavaScript" type="text/javascript" src="scripts/htmlutils.js"></script>
+ <script language="JavaScript" type="text/javascript" src="scripts/ui-element.js"></script>
<script language="JavaScript" type="text/javascript" src="lib/scriptaculous/scriptaculous.js"></script>
- <script language="JavaScript" type="text/javascript" src="lib/cssQuery/cssQuery-p.js"></script>
<script language="JavaScript" type="text/javascript" src="scripts/selenium-browserdetect.js"></script>
<script language="JavaScript" type="text/javascript" src="scripts/selenium-browserbot.js"></script>
<script language="JavaScript" type="text/javascript" src="scripts/find_matching_child.js"></script>
@@ -42,13 +42,15 @@ to work-around a bug in IE on Win2K whereby the HTA application doesn't function
<script language="JavaScript" type="text/javascript" src="scripts/selenium-testrunner.js"></script>
<script language="JavaScript" type="text/javascript" src="scripts/selenium-logging.js"></script>
<script language="JavaScript" type="text/javascript" src="scripts/selenium-version.js"></script>
- <script language="JavaScript" type="text/javascript" src="xpath/misc.js"></script>
+ <script language="JavaScript" type="text/javascript" src="xpath/util.js"></script>
+ <script language="JavaScript" type="text/javascript" src="xpath/xmltoken.js"></script>
<script language="JavaScript" type="text/javascript" src="xpath/dom.js"></script>
<script language="JavaScript" type="text/javascript" src="xpath/xpath.js"></script>
+ <script language="JavaScript" type="text/javascript" src="xpath/javascript-xpath-0.1.11.js"></script>
<script language="JavaScript" type="text/javascript" src="scripts/user-extensions.js"></script>
<script language="JavaScript" type="text/javascript">
function openDomViewer() {
- var autFrame = document.getElementById('myiframe');
+ var autFrame = document.getElementById('selenium_myiframe');
var autFrameDocument = new SeleniumFrame(autFrame).getDocument();
this.rootDocument = autFrameDocument;
var domViewer = window.open(getDocumentBase(document) + 'domviewer/domviewer.html');
@@ -68,14 +70,14 @@ to work-around a bug in IE on Win2K whereby the HTA application doesn't function
<iframe name="testSuiteFrame" id="testSuiteFrame" src="./TestPrompt.html" application="yes"></iframe>
</td>
<td width="50%" height="30%">
- <iframe name="testFrame" id="testFrame" application="yes"></iframe>
+ <iframe name="testFrame" id="testFrame" application="yes" src="Blank.html"></iframe>
</td>
<td width="25%">
<table class="layout">
<tr class="selenium">
<th width="25%" height="1" class="header">
- <h1><a href="http://selenium.thoughtworks.com" title="The Selenium Project">Selenium</a> TestRunner
+ <h1><a href="http://selenium.openqa.org" title="The Selenium Project">Selenium</a> TestRunner
</h1>
</th>
</tr>
@@ -86,16 +88,16 @@ to work-around a bug in IE on Win2K whereby the HTA application doesn't function
<div id="imageButtonPanel">
<button type="button" id="runSuite" onClick="htmlTestRunner.startTestSuite();"
- title="Run All tests">
+ title="Run All tests" accesskey="a">
</button>
<button type="button" id="runSeleniumTest" onClick="htmlTestRunner.runSingleTest();"
- title="Run the Selected test">
+ title="Run the Selected test" accesskey="r">
</button>
<button type="button" id="pauseTest" disabled="disabled"
- title="Pause/Continue" class="cssPauseTest">
+ title="Pause/Continue" accesskey="p" class="cssPauseTest">
</button>
<button type="button" id="stepTest" disabled="disabled"
- title="Step">
+ title="Step" accesskey="s">
</button>
</div>
@@ -164,7 +166,7 @@ to work-around a bug in IE on Win2K whereby the HTA application doesn't function
<tr>
<td colspan="3" height="70%">
- <iframe name="myiframe" id="myiframe" src="TestRunner-splash.html"></iframe>
+ <iframe name="selenium_myiframe" id="selenium_myiframe" src="TestRunner-splash.html"></iframe>
</td>
</tr>
Oops, something went wrong.

0 comments on commit fb1727f

Please sign in to comment.