diff --git a/extensions/amp-font/0.1/amp-font.js b/extensions/amp-font/0.1/amp-font.js index 6c2d8a6bf8f4..c2d554af3f77 100644 --- a/extensions/amp-font/0.1/amp-font.js +++ b/extensions/amp-font/0.1/amp-font.js @@ -72,6 +72,9 @@ const DEFAULT_SIZE_ = 'medium'; */ const CACHED_FONT_LOAD_TIME_ = 100; +/** @const {string} */ +const TAG_ = 'AmpFont'; + export class AmpFont extends AMP.BaseElement { @@ -124,7 +127,8 @@ export class AmpFont extends AMP.BaseElement { this.onFontLoadSuccess_(); }).catch(error => { this.onFontLoadError_(); - throw error; + console./* OK */warn( + 'Font download timed out for ' + this.fontFamily_); }); } diff --git a/test/integration/test-example-validation.js b/test/integration/test-example-validation.js index 1b4a74f39a69..e358df9c62a8 100644 --- a/test/integration/test-example-validation.js +++ b/test/integration/test-example-validation.js @@ -62,15 +62,11 @@ describe('example', function() { * @constructor {!Array} */ const errorWhitelist = [ - // TODO(dvoytenko): Remove once validator supports "data-videoid" for - // "amp-youtube" elements. - /MANDATORY_ATTR_MISSING video-id/, - - // TODO(dvoytenko): Remove once validator supports "amp-font" element. - /DISALLOWED_TAG amp-font/, - // Remove once validator supports "amp-brightcove". - /DISALLOWED_TAG amp-brightcove/ + /DISALLOWED_TAG amp-brightcove/, + + //Remove once validator is fixed. + /MANDATORY_ATTR_MISSING shortcode or src/ ]; const usedWhitelist = [];