* @param {string} name * @private
(name)
| 1760 | * @private |
| 1761 | */ |
| 1762 | dispatchEventForTesting_(name) { |
| 1763 | if (getMode().test) { |
| 1764 | let event; |
| 1765 | if (typeof this.localWin_.Event === 'function') { |
| 1766 | event = new Event(name, {bubbles: true, cancelable: true}); |
| 1767 | } else { |
| 1768 | event = this.localWin_.document.createEvent('Event'); |
| 1769 | event.initEvent(name, /* bubbles */ true, /* cancelable */ true); |
| 1770 | } |
| 1771 | this.localWin_.dispatchEvent(event); |
| 1772 | } |
| 1773 | } |
| 1774 | } |
| 1775 | |
| 1776 | class BindWalker { |
no test coverage detected