Skip to content

Commit

Permalink
Backport #32045
Browse files Browse the repository at this point in the history
tests: fix sanitizer test.

The test template does not include a `script` tag so the test always returned true.
  • Loading branch information
XhmikosR committed Nov 3, 2020
1 parent b953bc4 commit 56495e5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion js/tests/unit/tooltip.js
Expand Up @@ -1170,7 +1170,7 @@ $(function () {
})

var tooltip = $trigger.data('bs.tooltip')
assert.strictEqual(tooltip.config.template.indexOf('script'), -1)
assert.strictEqual(tooltip.config.template.indexOf('href="javascript:alert(7)"'), -1)
})

QUnit.test('should allow custom sanitization rules', function (assert) {
Expand Down

0 comments on commit 56495e5

Please sign in to comment.