Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(211)

Side by Side Diff: pkg/polymer/lib/src/build/common.dart

Issue 179163007: [polymer] skip linter in tests (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: rebase Created 6 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « pkg/polymer/lib/deploy.dart ('k') | pkg/polymer/lib/transformer.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 /// Common methods used by transfomers. 5 /// Common methods used by transfomers.
6 library polymer.src.build.common; 6 library polymer.src.build.common;
7 7
8 import 'dart:async'; 8 import 'dart:async';
9 import 'dart:math' show min, max; 9 import 'dart:math' show min, max;
10 10
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
57 /// `type="application/dart"` scripts with equivalent *.dart.js files. 57 /// `type="application/dart"` scripts with equivalent *.dart.js files.
58 /// 58 ///
59 /// If [contentSecurityPolicy] enabled, this will reference files 59 /// If [contentSecurityPolicy] enabled, this will reference files
60 /// named *.dart.precompiled.js. 60 /// named *.dart.precompiled.js.
61 final bool directlyIncludeJS; 61 final bool directlyIncludeJS;
62 62
63 /// Run transformers to create a releasable app. For example, include the 63 /// Run transformers to create a releasable app. For example, include the
64 /// minified versions of the polyfills rather than the debug versions. 64 /// minified versions of the polyfills rather than the debug versions.
65 final bool releaseMode; 65 final bool releaseMode;
66 66
67 /// True to run liner on all html files before starting other phasese.
Siggi Cherem (dart-lang) 2014/02/26 22:39:38 phasese => phases
Jennifer Messerly 2014/02/28 03:00:23 Done. Also added bug reference.
68 final bool lint;
69
67 TransformOptions({entryPoints, this.contentSecurityPolicy: false, 70 TransformOptions({entryPoints, this.contentSecurityPolicy: false,
68 this.directlyIncludeJS: true, this.releaseMode: true}) 71 this.directlyIncludeJS: true, this.releaseMode: true, this.lint: true})
69 : entryPoints = entryPoints == null ? null 72 : entryPoints = entryPoints == null ? null
70 : entryPoints.map(_systemToAssetPath).toList(); 73 : entryPoints.map(_systemToAssetPath).toList();
71 74
72 /// Whether an asset with [id] is an entry point HTML file. 75 /// Whether an asset with [id] is an entry point HTML file.
73 bool isHtmlEntryPoint(AssetId id) { 76 bool isHtmlEntryPoint(AssetId id) {
74 if (id.extension != '.html') return false; 77 if (id.extension != '.html') return false;
75 78
76 // Note: [id.path] is a relative path from the root of a package. 79 // Note: [id.path] is a relative path from the root of a package.
77 if (entryPoints == null) { 80 if (entryPoints == null) {
78 return id.path.startsWith('web/') || id.path.startsWith('test/'); 81 return id.path.startsWith('web/') || id.path.startsWith('test/');
(...skipping 184 matching lines...) Expand 10 before | Expand all | Expand 10 after
263 var scanner = new Scanner(null, reader, errorListener); 266 var scanner = new Scanner(null, reader, errorListener);
264 var token = scanner.tokenize(); 267 var token = scanner.tokenize();
265 var parser = new Parser(null, errorListener); 268 var parser = new Parser(null, errorListener);
266 return parser.parseCompilationUnit(token); 269 return parser.parseCompilationUnit(token);
267 } 270 }
268 271
269 class _ErrorCollector extends AnalysisErrorListener { 272 class _ErrorCollector extends AnalysisErrorListener {
270 final errors = <AnalysisError>[]; 273 final errors = <AnalysisError>[];
271 onError(error) => errors.add(error); 274 onError(error) => errors.add(error);
272 } 275 }
OLDNEW
« no previous file with comments | « pkg/polymer/lib/deploy.dart ('k') | pkg/polymer/lib/transformer.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698