Commit Graph

308 Commits

Author SHA1 Message Date
Oleg Gaidarenko
8e5d1caf7a Tests: More improvments for testrunner
Conform to style guide and simplify it
2014-04-15 17:45:58 +04:00
Oleg Gaidarenko
92cff8b1a3 Tests: Remove Sizzle intergration tests
Fixes #14818
2014-04-15 17:45:58 +04:00
Oleg Gaidarenko
a7c9facc35 Tests: Simplify globals cleanup 2014-04-15 17:45:58 +04:00
Oleg Gaidarenko
7149726485 Tests: Remove QUnit start hook 2014-04-15 17:45:58 +04:00
Oleg Gaidarenko
e0b606d2bd Tests: Remove uselss "keys" helper 2014-04-15 17:45:58 +04:00
Oleg Gaidarenko
b26628a2bb Tests: Simplify "testTimeout" option 2014-04-15 17:45:58 +04:00
Michał Gołębiowski
a10aa3aac5 Core: Change the sleep time in dont_return.php from 100s to 30s
Half a minute is more than enough for the test to finish even in the slowest
browsers and in case of starving the PHP FPM process pool, one has to wait
for only half a minute to try again.
2014-03-19 02:29:04 +01:00
Michał Gołębiowski
b5074944b0 Core: Change the sleep time in dont_return.php to a sane value
PHP sleep function accepts time in seconds, not milliseconds; the previous
value was starving the PHP FPM process pool.
2014-03-18 16:50:04 +01:00
Michał Gołębiowski
854d242db4 Core: Bump timeouts to stabilize doc ready test
The "document ready when jQuery loaded asynchronously" test fails all the time
in iOS7 and sometimes in other browsers. Bumping the timeouts *might* help
these other browsers to be less flakey here.
2014-03-13 03:26:42 +01:00
Dave Methvin
2df1aad6a1 Core: Do not run window.onready when ready
Fixes #14802
2014-03-04 21:00:04 -05:00
Dave Methvin
06adf7c95d Event: Allow triggerHandler(beforeunload)
Fixes #14791
2014-03-04 20:49:57 -05:00
Dave Methvin
3a68c114e3 Ajax: .load() should trim its selector
Fixes #14773
2014-03-04 20:43:14 -05:00
Oleg
38c122a73a Tests: Remove one of the checks for memory leak
This check is redundant since jQuery.fragments object does not exist anymore
2014-01-14 22:01:39 +04:00
cjqed
537e9ced61 Tests: Avoid use of QUnit.reset() in tests by splitting them
Fix #14040
Close gh-1457
2013-12-23 17:21:22 -05:00
Timmy Willison
f9ad13c9ec Manage bower dependencies with grunt-bowercopy
Tracked bower dependencies are located at "src/sizzle" and "test/libs".
The source-destination mapping is in the Gruntfile.

When updating a bower dependency, update the version in bower.json, run
`grunt bower`, and then commit the result. When adding a dependency,
update the bowercopy task accordingly.

Fixes #14615.
Closes gh-1452.
2013-12-06 16:04:35 -05:00
Corey Frang
d2aa969206 Ajax: Use weak ETag header in tests
See http://en.wikipedia.org/wiki/HTTP_ETag#Strong_and_weak_validation

Close gh-1448
2013-11-26 14:04:55 -05:00
hongymagic
8d09ee0506 Ref #14503: Cherry-pick tests.
(cherry picked from commit 27b22f4ef5)
(cherry picked from commit 8dc0f2ea84)
(cherry picked from commit 936126f10d)
2013-11-15 12:19:05 -05:00
Timmy Willison
ac7ff97f8b Use grunt and bower packages as local dependencies. Close gh-1433. 2013-11-14 10:17:18 -05:00
Dave Methvin
1cecf64e5a Fix #14180. Allow cross-frame use of focusin/out. Close gh-1369. 2013-11-12 21:15:08 -05:00
Michał Gołębiowski
4b39a82890 Fix #14340. Remove remnants of oldIE from unit tests. Close gh-1425. 2013-11-11 00:43:27 +01:00
Oleg
626cbde7f8 Use full version of jQuery 1.9.1
Had some weird failures in IE with xhr build of 1.9.1
2013-11-08 01:04:08 +01:00
Oleg
ee0d0e6e3f Add more thorough check for CSP violations 2013-11-07 20:16:19 +01:00
Richard Gibson
c66a5e70f2 Fix #14074: element id="nodeName". Close gh-1389.
(cherry picked from commit 126d596b56)

Conflicts:

	src/data.js
	src/data/accepts.js
	test/unit/core.js
	test/unit/data.js
2013-11-07 11:57:41 -05:00
Richard Gibson
d5b7139abc Ref f9d41ac6: Opera-compatible form target 2013-11-04 09:36:16 -05:00
Richard Gibson
f9d41ac641 Fix #14379: AJAX requests on unload 2013-10-28 17:53:31 -04:00
Dave Methvin
eca79fbf5b Revert "Fix #14180. Allow cross-frame use of focusin/out. Close gh-1369."
This reverts commit 9b6f074580.
2013-10-22 22:49:03 -04:00
Dave Methvin
9b6f074580 Fix #14180. Allow cross-frame use of focusin/out. Close gh-1369. 2013-10-22 22:03:20 -04:00
Richard Gibson
13d58a9bec No ticket: Fix subproject iframe tests 2013-10-11 15:08:07 -04:00
Timmy Willison
5093b89f08 Convert testrunner to an AMD module and ensure jQuery is on the page when executing the testrunner (another race condition amplified by swarm) 2013-09-06 17:11:32 -04:00
Timmy Willison
4ca5a0c691 No ticket: link testinit 2013-09-06 16:25:33 -04:00
Timmy Willison
e563cd3414 Move test loader to testinit.js. Fix race condition with dependency loading. 2013-09-06 16:23:20 -04:00
Timmy Willison
6535cc599e Use requirejs to load the testswarm inject script 2013-09-06 15:44:59 -04:00
Michał Gołębiowski
bbbdd94725 Fix #10814. Make support tests lazy and broken out to components. 2013-09-06 03:38:22 +02:00
Michał Gołębiowski
776012b8b3 Fix #14084: attach the test div to documentElement, not body. 2013-09-05 18:26:21 +02:00
Richard Gibson
0c18520923 No ticket: Hide the testing-support jQuery from tests 2013-09-03 10:43:32 -04:00
Timmy Willison
004c1fc5bb Pass all tests (and load Sizzle fixture correctly) when loading with AMD 2013-08-29 16:18:17 -04:00
Timmy Willison
62da89b89a Revert "Close php tags for ajax tests on swarm"
This reverts commit f6e86c3ca4.
2013-08-19 18:27:30 -04:00
Timmy Willison
f6e86c3ca4 Close php tags for ajax tests on swarm 2013-08-19 16:05:27 -04:00
Timmy Willison
6318ae6ab9 AMD-ify jQuery sourcegit s! Woo! Fixes #14113, #14163. 2013-08-15 14:15:49 -04:00
Richard Gibson
db0326b1fd Fix #13596; #13722: .replaceWith consistency. Close gh-1216. 2013-04-16 17:47:21 -04:00
Michał Gołębiowski
562ca75e06 Correct spacing. 2013-04-15 19:26:34 +02:00
Timmy Willison
0fa52c11cb Update jshintrc to conform to new style guide. Conform to onevar and unused in tests. Fixes #13755. 2013-04-09 11:59:31 -04:00
Dave Methvin
85fc5878b3 Fix #13393. Avoid IE9 activeElement of death. 2013-04-08 21:35:48 -04:00
Michał Gołębiowski
32b066d380 Fix #13655. Add test for jQuery.ready.promise fallback load. Close gh-1209. 2013-04-04 13:32:25 -04:00
Michał Gołębiowski
8db7d6f20b Fix #13543. offsetWidth is wrong on non-1 zoom. Close gh-1194. 2013-04-03 21:00:38 -04:00
jrburke
34c4e122a3 Remove the define.amd.jQuery check, ref gh-1150. 2013-02-28 17:21:18 -05:00
jaubourg
eebc77849c Fixes #11151, #13388. Minor refactor of response conversion and when/where
responseXXX fields are set on the jqXHR. Close gh-1164.

(Cherry-picked from 69b3d5ce0f)
2013-02-28 15:01:10 -05:00
Richard Gibson
59f5adb622 No ticket: Revise unit tests in anticipation of Sizzle-free builds 2013-02-22 20:13:36 -05:00
Richard Gibson
6971d9d8e2 Fix 363299ac failures 2013-02-07 17:03:04 -05:00
Richard Gibson
363299ac24 Ref #13316: Sync all documents on full vs. minified source. Close gh-1147. 2013-02-07 15:16:28 -05:00
Oleg
f3db084f7c Fix #13310. Get the right display value for disconnected nodes. Close gh-1156. 2013-02-04 15:22:07 -05:00
Rick Waldron
7b50c4a711 Avoid potential for breakage if test suite is run in a frame
Signed-off-by: Rick Waldron <waldron.rick@gmail.com>
2013-02-03 17:58:07 -05:00
Rick Waldron
7f94a5cc3a 2.0: Rewrite data.js (Incl. event, manipulation, tests) 2013-02-03 15:27:55 -05:00
Dave Methvin
58cd84f9d5 Fix #13316. Use minified version in unit testing. 2013-01-26 10:48:10 -05:00
Richard Gibson
487b703521 Fix #13274: Wrap sourceMap directive in multiline comments. Close gh-1143.
(cherry picked from commit ac93559eb9)
2013-01-25 10:09:27 -05:00
byroot
bfc61b879e Don't try and convert data for 204 No Content responses. Fixes #13292. Fixes #13261. 2013-01-24 02:34:02 +01:00
jaubourg
62acda819f Adds the abort on unload trick back in since IE9 still exhibits the bug 2013-01-07 10:34:14 -05:00
Dave Methvin
445dbd9d95 Revert data.js rewrite.
Reverts the following commits:

commit f717226b3a
Author: Rick Waldron <waldron.rick@gmail.com>
Date:   Mon Dec 31 18:06:38 2012 -0500

Only splice from internal arrays when item actually exists.

commit b9cdc4136b
Author: Rick Waldron <waldron.rick@gmail.com>
Date:   Mon Dec 31 16:20:35 2012 -0500

Updates to data.js re-write to pass events and manipulation

commit d1de3000c6
Author: Rick Waldron <waldron.rick@gmail.com>
Date:   Mon Dec 31 15:09:45 2012 -0500

2.0: Rewrite data.js
2013-01-03 20:43:01 -05:00
Rick Waldron
d1de3000c6 2.0: Rewrite data.js
Signed-off-by: Rick Waldron <waldron.rick@gmail.com>
2012-12-31 16:23:20 -05:00
Richard Gibson
2ea7876c25 Fix #13064: better test fixture cleanup. Close gh-1075. 2012-12-16 13:09:40 -05:00
Timo Tijhof
55313d32a2 Test: Update index.html to new QUnit format. Close gh-1061.
Depends on jquery/sizzle#177, included with the Sizzle submodule in this commit.
2012-12-10 21:48:20 -05:00
Timo Tijhof
cef044d82e Test: Remove fixtures from QUnit.done hook. Close gh-1069.
This fixes jquery/testswarm#197. These are currently removed from
the TestSwarm injector, however this is jQuery specific, and
should be done from this end instead.
2012-12-10 20:45:20 -05:00
Timo Tijhof
5dd8a90f73 Make compatible with jshint, lint test/data. Close gh-1043. 2012-12-06 13:46:37 -05:00
jaubourg
b7ece8c620 Revert "Organizes the php scripts used for testing better, so that the whole logic of a unit, server-side and client-side, is contained within the unit itself. Nearly all ajax unit tests take advantage of the new 'framework'. Lots of files got deleted because they became redundant or weren't used anymore."
This reverts commit 228ab3ddae.
2012-12-05 14:54:14 +01:00
jaubourg
7f7007dffe Revert "228ab3d followup 1: fix test failures. Close gh-1056."
This reverts commit 20608b3579.
2012-12-05 14:54:00 +01:00
Richard Gibson
20608b3579 228ab3d followup 1: fix test failures. Close gh-1056. 2012-12-05 02:12:32 -05:00
jaubourg
228ab3ddae Organizes the php scripts used for testing better, so that the whole logic of a unit, server-side and client-side, is contained within the unit itself. Nearly all ajax unit tests take advantage of the new 'framework'. Lots of files got deleted because they became redundant or weren't used anymore. 2012-12-04 07:40:12 +01:00
Richard Gibson
4ada325479 More improvements per @jaubourg 2012-12-03 11:32:19 -05:00
Richard Gibson
ad690f8151 Improvements per @jaubourg 2012-12-03 00:49:40 -05:00
Richard Gibson
5b9bf13439 No ticket: improve global variable/ajax request tracking 2012-12-02 23:32:16 -05:00
jaubourg
b9dfcfd736 sandboxes start for real this time (fixes test failures in IE) 2012-11-27 02:39:08 +01:00
jaubourg
603e70b90e Greatly simplifies ajaxTest 2012-11-26 11:49:20 +01:00
jaubourg
d31cef38f2 Total revamping of the ajax unit tests 2012-11-26 03:31:19 +01:00
Richard Gibson
81b094b2c1 No ticket: update test suite to pass QUnit globals check in most environments. Close gh-1016. 2012-11-05 17:24:03 -05:00
Richard Gibson
53cb49cb0a Remove gratuitous punctuation 2012-11-01 22:22:39 -04:00
Richard Gibson
3f51504580 No ticket: remove test suite external dependencies 2012-11-01 17:32:08 -04:00
Richard Gibson
14e1501b89 Fix testing of no-ajax custom builds 2012-11-01 00:40:27 -04:00
Timo Tijhof
6e75fe5f19 No ticket: fix effects test failure in IE6. Close gh-1012. 2012-10-31 16:41:31 -04:00
Timo Tijhof
36c9ecb0f5 Implement expectation test instead of using _removeData. Close gh-997.
* Removed inline usage of QUnit.reset() because it is messing with the
  expectation model as reset does .empty() which does a recursive cleanData
  on everything in #qunit-fixture, so any expectJqData above .reset() would
  fail negatively.

  Instead of calling reset inline, either updated the following assertions to
  take previous assertions' state into account, or broke the test() up into
  2 tests at the point where it would call QUnit.reset.

* After introducing the new memory leak discovery a whole bunch of tests were
  failing as they didn't clean up everything. However I didn't (yet) add
  QUnit.expectJqData calls all over the place because in most if not all of
  these cases it is valid data storage. For example in test "data()", there
  will be an internal data key for "parsedAttrs". This particular test isn't
  intending to test for memory leaks, so therefor I made the new discovery
  system only push failures when the test contains at least 1 call to
  QUnit.expectJqData.

  When not, we'll assume that whatever data is being stored is acceptable
  because the relevant elements still exist in the DOM anyway (QUnit.reset
  will remove the elements and clean up the data automatically).

  I did add a "Always check jQuery.data" mode in the test suite that will
  trigger it everywhere. Maybe one day we'll include a call to everywhere,
  but for now I'm keeping the status quo: Only consider data left in storage
  to be a problem if the test says so ("opt-in").

* Had to move #fx-tests inside the fixture because ".remove()" test would
  otherwise remove stuff permanently and cause random other tests to fail
  as "#hide div" would yield an empty collection.
  (Why wasn't this in the fixture in the first place?)

  As a result moving fx-tests into the fixture a whole bunch of tests failed
  that relied on arbitrary stuff about the document-wide or fixture-wide
  state (e.g. number of divs etc.). So I had to adjust various tests to
  limit their sample data to not be so variable and unlimited...

* Moved out tests for expando cleanup into a separate test.

* Fixed implied global variable 'pass' in effects.js that was causing
  "TypeError: boolean is not a function" in *UNRELATED* dimensions.js that
  uses a global variable "pass = function () {};" ...

* Removed spurious calls to _removeData. The new test exposed various failures
  e.g. where div[0] isn't being assigned any data anyway.
  (queue.js and attributes.js toggleClass).

* Removed spurious clean up at the bottom of test() functions that are
  already covered by the teardown (calling QUnit.reset or removeClass to
  supposedly undo any changes).

* Documented the parentheses-less magic line in toggleClass. It appeared that
  it would always keep the current class name if there was any (since the
  assignment started with "this.className || ...".

  Adding parentheses + spacing is 8 bytes (though only 1 in gzip apparently).
  Only added the comment for now, though I prefer clarity with logical
  operators, I'd rather not face the yayMinPD[1] in this test-related commit.

* Updated QUnit urlConfig to the new format (raw string is deprecated).

* Clean up odd htmlentities in test titles, QUnit escapes this.
  (^\s+test\(.*)(&gt\;) → $1>
  (^\s+test\(.*)(&lt\;) → $1<

[1] jQuery MinJsGz Release Police Department (do the same, download less)
2012-10-28 22:44:57 -04:00
Daniel Gálvez
b398a68333 Fix #11542. document.body should not be special in .offset() and document.documentElement is the default element.offsetParent. Close gh-899. 2012-10-24 23:35:15 -04:00
Sai Wong
2b0e720406 Fix #12048. Set attributes for XML fragments. Close gh-965. 2012-10-20 15:27:43 -04:00
Richard Gibson
c31539c8a2 no ticket: fix jQuery suite failure on Android 2012-10-17 15:20:50 -04:00
Mike Petrovich
861476eb3f Fixes #11635, Explicit overflow:auto is overridden by inline overflow:hidden during animation, closes gh-981 2012-10-16 12:30:28 -04:00
Rick Waldron
611d7660cd Remove duplicate expect. Add QUnit.config.requireExpects to testrunner.js QUnit configurations. 2012-10-15 12:31:27 -04:00
Timo Tijhof
7e8b854152 Test: Clean up and fix misc issues
* Clean up testinit and testrunner

* Uncomment isLocal (at least make sure it is declared)

* Rephrase environment assertions to make sense if one reads
  them when they pass.

* Optimise an expensive loop that might be the cause of this
  in IE6: http://cl.ly/image/3f20053m112n
2012-10-09 20:06:31 -04:00
Mike Sherov
a9c2a9bf61 Scorch the earth and retreat on readyState interactive! Close gh-907. 2012-08-23 20:28:22 -04:00
Elijah Manor
10901f7d9f Fix #12266. IE9/10 says document[0] is document.frames[0]? Close gh-903. 2012-08-22 21:48:02 -04:00
Dave Methvin
ae1d2b3173 Neuter the partialLoadReady test until it's ngnix-ready 2012-08-22 21:47:59 -04:00
Mike Sherov
0f553ed0ca Fix #12282. IE has premature .readyState == "interactive". Close gh-901. 2012-08-20 08:16:07 -04:00
Dave Methvin
2b2ca8baa3 Don't expect QUnit to clean up jQuery internal data. Close gh-883. 2012-08-19 21:09:13 -04:00
Richard Gibson
ff7a434562 Really support subproject tests in testswarm, closes gh-868 2012-07-22 21:49:39 -04:00
Dave Methvin
3016872220 Let subproject tests use their own test fixture. Closes gh-867. 2012-07-19 22:02:37 -04:00
Dave Methvin
2d09e9a325 Image location is relative to css file, not html file. 2012-07-12 11:57:28 -04:00
Dave Methvin
f4e5c1729a Fix #11547. toLowerCase not work good on XML attributes.
This was fixed to some extent in gh-724 but there were insufficient test cases. Removing the lowercase completely allows IE 6/7 to work properly since there you need an exact case match for attributes, even in HTML docs. More discussion and test cases in the comments on gh-724.
2012-07-11 23:09:07 -04:00
Mike Sherov
f5fd41252e Fix #12018, readyState "interactive" in oldIE lies! Closes gh-848. 2012-07-06 10:12:20 -04:00
Richard Gibson
1793eab32b Fix #11971: force numeric animation start to be numeric, closes gh-836. 2012-07-05 21:38:17 -04:00
Rick Waldron
a2758377df Adds src/deprecated.js, test/unit/deprecated.js; -deprecated flag; Moves jQuery.browser and removes use in test/unit/ajax.js. Fixes #11965 2012-06-25 10:02:28 -04:00
Dave Methvin
83dfb99ea9 Tweak test for #11743 in an attempt to placate Jenkins.
I can't get the current test to fail locally or in Browserstack, but suspect it may have something to do with badjson.js.
2012-06-11 22:35:04 -04:00
Timo Tijhof
849303701a Test: Remove unused file "include_js.php", closes gh-820. 2012-06-11 21:18:17 -04:00
jaubourg
cac5b08f72 Here is hoping everything works with the full build and the build without ajax... looking at you @dmethvin ;) 2012-06-11 21:04:34 +02:00