diff options
author | GeoSot <geo.sotis@gmail.com> | 2021-05-20 16:16:55 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-05-20 16:16:55 +0300 |
commit | 9e4f87ae8f2e32bb31795ece8f9ab3e7b823dd7d (patch) | |
tree | a8ae05c59e1e245dc9fa52ea85863c844879b8a1 /js/tests/unit/popover.spec.js | |
parent | de0b797ab2bb80e4576c15f1992dc5755378edcd (diff) |
Allow use of `dispose/hide` methods on Tooltip & Popover from jQueryInterface, when component does not exists. (#33371)
Diffstat (limited to 'js/tests/unit/popover.spec.js')
-rw-r--r-- | js/tests/unit/popover.spec.js | 15 |
1 files changed, 0 insertions, 15 deletions
diff --git a/js/tests/unit/popover.spec.js b/js/tests/unit/popover.spec.js index 7c741fe470..def0f5f040 100644 --- a/js/tests/unit/popover.spec.js +++ b/js/tests/unit/popover.spec.js @@ -266,21 +266,6 @@ describe('Popover', () => { expect(popover.show).toHaveBeenCalled() }) - - it('should do nothing if dipose is called when a popover do not exist', () => { - fixtureEl.innerHTML = '<a href="#" title="Popover" data-bs-content="https://twitter.com/getbootstrap">BS twitter</a>' - - const popoverEl = fixtureEl.querySelector('a') - - jQueryMock.fn.popover = Popover.jQueryInterface - jQueryMock.elements = [popoverEl] - - spyOn(Popover.prototype, 'dispose') - - jQueryMock.fn.popover.call(jQueryMock, 'dispose') - - expect(Popover.prototype.dispose).not.toHaveBeenCalled() - }) }) describe('getInstance', () => { |