MCPcopy Index your code
hub / github.com/ampproject/amphtml / CompileValidatorMinified

Function CompileValidatorMinified

validator/build.py:293–316  ·  view source on GitHub ↗

Generates a minified validator script, which can be imported to validate. Args: out_dir: output directory

(out_dir)

Source from the content-addressed store, hash-verified

291
292
293def CompileValidatorMinified(out_dir):
294 """Generates a minified validator script, which can be imported to validate.
295
296 Args:
297 out_dir: output directory
298 """
299 logging.info('entering ...')
300 CompileWithClosure(
301 js_files=[
302 'js/engine/definitions.js', 'js/engine/htmlparser.js',
303 'js/engine/parse-css.js', 'js/engine/parse-srcset.js',
304 'js/engine/parse-url.js', 'js/engine/tokenize-css.js',
305 '%s/validator-generated.js' % out_dir,
306 '%s/validator-proto-generated.js' % out_dir,
307 'js/engine/validator-in-browser.js', 'js/engine/validator.js',
308 'js/engine/amp4ads-parse-css.js', 'js/engine/keyframes-parse-css.js',
309 'js/engine/htmlparser-interface.js'
310 ],
311 definitions=[],
312 entry_points=[
313 'amp.validator',
314 ],
315 output_file='%s/validator_minified.js' % out_dir)
316 logging.info('... done')
317
318
319def RunSmokeTest(out_dir):

Callers 1

MainFunction · 0.85

Calls 2

CompileWithClosureFunction · 0.85
infoMethod · 0.80

Tested by

no test coverage detected