mirror of
https://github.com/twbs/bootstrap.git
synced 2025-08-13 00:54:04 +02:00
Regression on tooltip template creation process. (#34628)
* Regression on tooltip template creation process. * check if template content does not exist, or given argument is empty * call `setContent()` once.
This commit is contained in:
@@ -1045,10 +1045,10 @@ describe('Tooltip', () => {
|
||||
const tooltipEl = fixtureEl.querySelector('a')
|
||||
const tooltip = new Tooltip(tooltipEl)
|
||||
|
||||
tooltip.setContent()
|
||||
|
||||
const tip = tooltip.getTipElement()
|
||||
|
||||
tooltip.setContent(tip)
|
||||
|
||||
expect(tip.classList.contains('show')).toEqual(false)
|
||||
expect(tip.classList.contains('fade')).toEqual(false)
|
||||
expect(tip.querySelector('.tooltip-inner').textContent).toEqual('Another tooltip')
|
||||
|
Reference in New Issue
Block a user