* @param {string=} opt_src * @param {string=} opt_attributionsrc * @return {!Promise<?Image>}
(opt_src, opt_attributionsrc)
| 41 | * @return {!Promise<?Image>} |
| 42 | */ |
| 43 | function trigger(opt_src, opt_attributionsrc) { |
| 44 | if (opt_src != null) { |
| 45 | pixel.setAttribute('src', opt_src); |
| 46 | } |
| 47 | if (opt_attributionsrc != null) { |
| 48 | pixel.setAttribute('attributionsrc', opt_attributionsrc); |
| 49 | } |
| 50 | whenFirstVisibleResolver(); |
| 51 | return whenFirstVisiblePromise |
| 52 | .then(() => { |
| 53 | return pixel.getImpl(false); |
| 54 | }) |
| 55 | .then((impl) => { |
| 56 | expect(impl.triggerPromise_).to.be.not.null; |
| 57 | return impl.triggerPromise_; |
| 58 | }); |
| 59 | } |
| 60 | |
| 61 | it('should be non-displayed', () => { |
| 62 | expect(pixel.style.width).to.equal('0px'); |
no test coverage detected