aboutsummaryrefslogtreecommitdiffstats
path: root/build
diff options
context:
space:
mode:
authorJohn Resig <jeresig@gmail.com>2007-07-09 00:15:44 +0000
committerJohn Resig <jeresig@gmail.com>2007-07-09 00:15:44 +0000
commit54035207fe91cb57f49bb8c0c9f7b4ada8d05346 (patch)
tree3c2cb17caf1da7358801aa2a8476b176bb6292e9 /build
parentb09043fbf6d98adfd22f85a347256f545afb2c11 (diff)
downloadjquery-54035207fe91cb57f49bb8c0c9f7b4ada8d05346.tar.gz
jquery-54035207fe91cb57f49bb8c0c9f7b4ada8d05346.zip
Tweaked some of the tests, added in events and fx tests.
Diffstat (limited to 'build')
-rw-r--r--build/runtest/test.js7
-rw-r--r--build/runtest/testrunner.js23
2 files changed, 28 insertions, 2 deletions
diff --git a/build/runtest/test.js b/build/runtest/test.js
index d793ca811..1831e2f04 100644
--- a/build/runtest/test.js
+++ b/build/runtest/test.js
@@ -6,7 +6,12 @@ window.location = "test/index.html";
load("dist/jquery.js","build/runtest/testrunner.js");
// Load the tests
-load("src/jquery/coreTest.js","src/selector/selectorTest.js");
+load(
+ "src/jquery/coreTest.js",
+ "src/selector/selectorTest.js",
+ "src/event/eventTest.js",
+ "src/fx/fxTest.js"
+);
// Display the results
results();
diff --git a/build/runtest/testrunner.js b/build/runtest/testrunner.js
index 974410012..27822f9e3 100644
--- a/build/runtest/testrunner.js
+++ b/build/runtest/testrunner.js
@@ -160,4 +160,25 @@ function results(){
}
function start(){}
-function stop(){} \ No newline at end of file
+function stop(){}
+
+/**
+ * Trigger an event on an element.
+ *
+ * @example triggerEvent( document.body, "click" );
+ *
+ * @param DOMElement elem
+ * @param String type
+ */
+function triggerEvent( elem, type, event ) {
+/*
+ if ( jQuery.browser.mozilla || jQuery.browser.opera ) {
+ event = document.createEvent("MouseEvents");
+ event.initMouseEvent(type, true, true, elem.ownerDocument.defaultView,
+ 0, 0, 0, 0, 0, false, false, false, false, 0, null);
+ elem.dispatchEvent( event );
+ } else if ( jQuery.browser.msie ) {
+ elem.fireEvent("on"+type);
+ }
+*/
+} \ No newline at end of file