aboutsummaryrefslogtreecommitdiffstats
path: root/test/unit/manipulation.js
Commit message (Collapse)AuthorAgeFilesLines
* Tests: Workaround failures in recent XSS tests in iOS 8 - 12Michał Gołębiowski-Owczarek2020-04-301-7/+15
| | | | | | | | | | iOS 8-12 parses `<noembed>` tags differently, executing this code. This is no different to native behavior on that OS, though, so just accept it. Ref gh-4685 Closes gh-4694 (cherry picked from commit 11066a9e6ac183dd710d1bc7aa74a3f809757136)
* Docs: Fix typosPierre Grimaud2020-04-291-2/+2
| | | | | | Closes gh-4686 (cherry picked from commit 1a7332ce83cdee7d6cd9d45c2a4b83067f53f14b)
* Tests: Add tests for recently fixed manipulation XSS issuesMichał Gołębiowski-Owczarek2020-04-291-0/+49
| | | | | | | | Closes gh-4685 Ref gh-4642 Ref gh-4647 (cherry picked from commit dc06d68bdc4c2562b5cc530f21e668a17d78ee2d)
* Manipulation: Make jQuery.htmlPrefilter an identity functionMichał Gołębiowski-Owczarek2020-03-161-71/+67
| | | | | | Closes gh-4642 (cherry picked from 90fed4b453a5becdb7f173d9e3c1492390a1441f)
* Core: Fire iframe script in its context, add doc param in globalEvalMichał Gołębiowski-Owczarek2020-02-101-0/+21
| | | | | | | | | | | | | 1. Support passing custom document to jQuery.globalEval; the script will be invoked in the context of this document. 2. Fire external scripts appended to iframe contents in that iframe context; this was already supported & tested for inline scripts but not for external ones. Fixes gh-4518 Closes gh-4601 (cherry picked from commit 4592595b478be979141ce35c693dbc6b65647173)
* Build:Tests: Fix custom build tests, verify on Travis; name Travis jobsMichał Gołębiowski-Owczarek2020-01-271-4/+5
| | | | | | | | | | | | | | | | This commit fixes unit tests for the following builds: 1. The no-deprecated build: `custom:-deprecated` 2. The current slim build: `custom:-ajax,-effects` 3. The 4.0 (#4553) slim build: `custom:-ajax,-callbacks,-deferred,-effects` It also adds separate Travis jobs for the no-deprecated & slim builds. Apart from that, add intuitive names to Travis jobs. Otherwise it's hard to see at a glance that a particular job is running on Firefox ESR, for example. Ref gh-4577 Ref gh-4596 Closes gh-4600
* Docs: Update links to EdgeHTML issues to go through Web ArchiveMichał Gołębiowski-Owczarek2020-01-081-22/+22
| | | | | | | | | | | | With Microsoft going Chromium with Edge, its old EdgeHTML issues were all removed. :( The commit also reformats one manipulation unit test to use tabs instead of spaces for indentation. (partially cherry-picked from 1dad1185e0b2ca2a13bf411558eda75fb2d4da88) Closes gh-4584
* Core: Preserve CSP nonce on scripts with src attribute in DOM manipulationbuddh42019-03-251-0/+23
| | | | | Fixes gh-4323 Closes gh-4328
* Build: Update QUnit from 1.23.1 to 2.9.2Michał Gołębiowski-Owczarek2019-03-041-2/+2
| | | Closes gh-4307
* Build: Update test code for compatibility with QUnit 2.x (#4297)abnud12019-02-181-36/+41
| | | | | | | | Also, run `grunt npmcopy` to sync the "external" directory with dependencies from package.json. For example, the Sinon library version didn't match. Ref gh-4234 Closes gh-4297
* Core: Support passing nonce through jQuery.globalEvalMichał Gołębiowski-Owczarek2019-01-211-0/+23
| | | | | | Fixes gh-4278 Closes gh-4280 Ref gh-3541 Ref gh-4269
* Manipulation: Respect script nomodule attribute in DOM manipulationMichał Gołębiowski-Owczarek2019-01-211-1/+31
| | | | | | | | | | | | | PR #3869 added support for `<script type="module">` & some support for the `nomodule` attribute but with no tests for `nomodule` and with the attribute only respected on inline scripts. This commit adds support for source-based scripts as well. It also adds tests for `nomodule`, including making sure legacy browsers execute such scripts as they'd natively do - that's the whole point of `nomodule` scripts, after all. Fixes gh-4281 Closes gh-4282 Ref gh-3871 Ref gh-3869
* Tests: Skip nonce tests in old iOS/Android as wellMichał Gołębiowski-Owczarek2019-01-141-2/+5
| | | | | | | | | | Old iOS & Android Browser versions support script-src but not nonce, making the nonce test impossible to run. Browsers not supporting CSP at all are not a problem as they'll skip script-src restrictions completely. Ref gh-3541 Ref gh-4269 Ref c7c2855ed13f23322c4064407c1ed84561b95738
* Core: Preserve CSP nonce on scripts in DOM manipulationMichał Gołębiowski-Owczarek2019-01-141-0/+20
| | | | Fixes gh-3541 Closes gh-4269
* Manipulation: Only evaluate HTTP-successful script srcRichard Gibson2018-12-121-0/+17
| | | | | Fixes gh-4126 Closes gh-4243
* Tests: Skip module tests in EdgeMichał Gołębiowski-Owczarek2018-07-301-1/+7
| | | | | | Edge sometimes doesn't execute module scripts. It needs to be investigated why but for now, we're skipping the test to make our tests more stable. Closes gh-4140
* Manipulation: Properly detect HTML elements with single-character namesRichard Gibson2018-07-131-0/+15
| | | | Fixes gh-4124 Closes gh-4125
* Tests: ensure that module assertions run on supported browsersTimmy Willison2018-01-161-8/+14
| | | | | | - Also fixes tests for karma, where the URL for the module is different Ref gh-3871
* Manipulation: Add support for scripts with module typebasil.belokon2018-01-161-0/+16
| | | | | Fixes gh-3871 Close gh-3869
* Core: deprecate jQuery.isFunctionJason Bedard2018-01-151-1/+1
| | | | Fixes gh-3609
* Tests: Add support for running unit tests via grunt with karmaTimo Tijhof2017-12-181-2/+2
| | | | | | | | | | | | | - Update QUnit to 1.23.1 - Remove unused dl#dl from test/index.html - Remove unused map#imgmap from test/index.html - Ensure all urls to data use baseURI - Add the 'grunt karma:main' task - customContextFile & customDebugFile - Add 'npm run jenkins' script Close gh-3744 Fixes gh-1999
* Tests: minor typosAndreas Solleder2017-06-051-1/+1
| | | | Close gh-3671
* Core: Deprecate jQuery.nodeNamekaran-962017-03-011-8/+8
| | | | | Fixes gh-3475 Closes gh-3505
* Manipulation: Restrict the tbody search to child nodesRichard Gibson2017-01-091-0/+20
| | | | | | | For performance, use a querySelectorAll path instead of Javascript iteration. http://codepen.io/anon/pen/vywJjx?editors=1010 Fixes gh-3439 Closes gh-3463
* Build: More ESLint related changesOleg Gaidarenko2016-07-091-1/+1
|
* Build: ESLint detailsOleg Gaidarenko2016-06-111-9/+9
| | | | | | Use eslint pragmas, fix new errors, etc Closes gh-3148
* Tests: Refactor testIframe() to make it DRYer and more consistentDave Methvin2016-04-111-5/+5
| | | | | Ref gh-3040 Closes gh-3049
* Docs:Tests: Remove obsolete code from tests, update support commentsMichał Gołębiowski2016-03-081-30/+2
| | | | | | | | | | Support comments that were lacking the final IE/Edge version that exhibits the bug were checked & updated. Links to the Chromium bug tracker were updated. Code in tests related to unsupported browsers (like Android 2.3 in non-basic tests) has been removed. Fixes gh-2868 Closes gh-2949
* Tests: Fix manipulation tests in Android 4.4Michał Gołębiowski2016-01-271-0/+12
| | | | | | Chromium < 35 incorrectly upper-cases µ; Android 4.4 uses such a version by default (and its WebView, being un-updatable, will use it for eternity) so we need to blacklist that one for the tests to pass.
* Docs: Updated links to https where they are supported.Jon Dufresne2016-01-131-1/+1
| | | | Close gh-2746
* Docs: Fix various spelling errorsJosh Soref2016-01-131-3/+3
| | | | Closes gh-2761
* Manipulation: Bring tagname regexes up to specLeonardo Braga2016-01-071-0/+67
| | | | | Fixes gh-2005 Closes gh-2634
* Selector: pass jQuery unit tests with selector-nativeTimmy Willison2015-11-111-101/+122
| | | | | | | | | - Ignore certain tests that obviously are not supported - Beefed up the sortOrder, uniqueSort, isXMLDoc, and attr functions Fixes gh-1742 Fixes gh-2048 Close gh-2703
* Manipulation: execute scripts from iframe in the iframe's contextTimmy Willison2015-11-091-0/+11
| | | | | Fixes gh-1757 Close gh-2696
* Data: avoid using delete on DOM nodesJason Bedard2015-09-081-2/+2
| | | | Closes gh-2479
* Tests: further improvements QUnit 2.0 migrationOleg Gaidarenko2015-09-081-4/+4
| | | | | | | | * Remove QUnit jshint globals * Extend QUnit.assert methods * Use assert.async instead of start/stop/done Ref b930d14ce64937e9478405eee2828d4da091d2cb
* Build: Update jscs and lint filesOleg Gaidarenko2015-09-071-789/+788
| | | | Fixes gh-2056
* Tests: partially use new qunit interfaceOleg Gaidarenko2015-08-161-671/+671
| | | | | | | | | | | | http://qunitjs.com/upgrade-guide-2.x/ For most of the boring work was used https://github.com/apsdehal/qunit-migrate package However, it can't update local qunit helpers, plus in some places old QUnit.asyncTest signature is still used Fixes gh-2540
* Tests: don't use deprecated argument in test declarationOleg Gaidarenko2015-07-301-7/+21
| | | | Closes gh-2507
* Docs: Fix various spelling mistakesBruno Pérel2015-07-301-1/+1
| | | | Closes gh-2487
* Data: remove user data in cleanDataJason Bedard2015-07-281-1/+23
| | | | | Fixes gh-2503 Closes gh-2480
* Ajax: Account for Android 2.3 not firing window.onerror on script errorsMichał Gołębiowski2015-07-281-0/+11
| | | | | | | | | | Android 2.3 doesn't fire the window.onerror handler, just accept the reality there and skip the test. Refs gh-1573 Refs gh-1786 Refs jquery/jquery.com#108 Closes gh-2458
* Manipulation: Make an HTML interception pointRichard Gibson2015-04-301-40/+75
| | | | | Fixes gh-1747 Closes gh-2203
* Manipulation: Detect sneaky no-content replaceWith inputRichard Gibson2015-04-301-4/+20
| | | | | | | Fixes gh-2204 Ref 642e9a45579cfa90861b8ea71a95dd077775caaf Closes gh-1752 Closes gh-2206
* Data: restore explicit data removal of private data in cleanData.Rick Waldron2015-03-091-0/+17
| | | | | Fixes gh-2127 Closes gh-2132
* Data: move element cache to element[expando]Rick Waldron2015-03-041-7/+2
| | | | | | | | | - avoid explicit data.discard() cleanup calls - explicitly remove the data.events property, only when private data exists - reduces code footprint Fixes gh-1734 Close gh-1428
* Build: fix broken assertions caused by QUnit updateOleg Gaidarenko2015-02-151-8/+8
| | | | | | | | QUnit update broke couple traversing and manipulation tests, since new qunit added another form to the test-suite while some of jQuery selectors weren't specific Ref 2d5c5d213f09fa0205d07a2d60a36581058cc40a
* Manipulation: don't auto-insert tbodyOleg Gaidarenko2015-02-111-0/+75
| | | | | Fixes gh-1835 Closes gh-2021
* Manipulation: simplify html wrappersOleg Gaidarenko2015-02-101-0/+12
| | | | | | | | Take advantage of html serialization for html wrappers - saves 26 bytes Plus add additional test for "col" element Closes gh-2031 Fixes gh-2002
* Manipulation: increase delay of data-URI testOleg Gaidarenko2015-01-261-1/+1
| | | | | | | For Safar7/Opera - shot in the dark, can't reproduce this locally Fixes gh-1993 (cherry-picked from 30ace26c42954497e44f19e8c7fa100de45c489e)