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

Side by Side Diff: pkg/analyzer/test/generated/engine_test.dart

Issue 842503003: Enable async support (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 5 years, 11 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
OLDNEW
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2014, 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 // This code was auto-generated, is not intended to be edited, and is subject to 5 // This code was auto-generated, is not intended to be edited, and is subject to
6 // significant change. Please see the README file for more information. 6 // significant change. Please see the README file for more information.
7 7
8 library engine.engine_test; 8 library engine.engine_test;
9 9
10 import 'dart:async'; 10 import 'dart:async';
(...skipping 200 matching lines...) Expand 10 before | Expand all | Expand 10 after
211 211
212 @override 212 @override
213 void setUp() { 213 void setUp() {
214 _context = new AnalysisContextImpl(); 214 _context = new AnalysisContextImpl();
215 _sourceFactory = new SourceFactory( 215 _sourceFactory = new SourceFactory(
216 [new DartUriResolver(DirectoryBasedDartSdk.defaultSdk), new FileUriResol ver()]); 216 [new DartUriResolver(DirectoryBasedDartSdk.defaultSdk), new FileUriResol ver()]);
217 _context.sourceFactory = _sourceFactory; 217 _context.sourceFactory = _sourceFactory;
218 AnalysisOptionsImpl options = 218 AnalysisOptionsImpl options =
219 new AnalysisOptionsImpl.con1(_context.analysisOptions); 219 new AnalysisOptionsImpl.con1(_context.analysisOptions);
220 options.cacheSize = 256; 220 options.cacheSize = 256;
221 options.enableAsync = true;
222 options.enableEnum = true; 221 options.enableEnum = true;
223 _context.analysisOptions = options; 222 _context.analysisOptions = options;
224 } 223 }
225 224
226 @override 225 @override
227 void tearDown() { 226 void tearDown() {
228 _context = null; 227 _context = null;
229 _sourceFactory = null; 228 _sourceFactory = null;
230 super.tearDown(); 229 super.tearDown();
231 } 230 }
(...skipping 2025 matching lines...) Expand 10 before | Expand all | Expand 10 after
2257 options.generateSdkErrors = booleanValue; 2256 options.generateSdkErrors = booleanValue;
2258 options.hint = booleanValue; 2257 options.hint = booleanValue;
2259 options.incremental = booleanValue; 2258 options.incremental = booleanValue;
2260 options.preserveComments = booleanValue; 2259 options.preserveComments = booleanValue;
2261 AnalysisOptionsImpl copy = new AnalysisOptionsImpl.con1(options); 2260 AnalysisOptionsImpl copy = new AnalysisOptionsImpl.con1(options);
2262 expect(copy.analyzeAngular, options.analyzeAngular); 2261 expect(copy.analyzeAngular, options.analyzeAngular);
2263 expect(copy.analyzeFunctionBodies, options.analyzeFunctionBodies); 2262 expect(copy.analyzeFunctionBodies, options.analyzeFunctionBodies);
2264 expect(copy.analyzePolymer, options.analyzePolymer); 2263 expect(copy.analyzePolymer, options.analyzePolymer);
2265 expect(copy.cacheSize, options.cacheSize); 2264 expect(copy.cacheSize, options.cacheSize);
2266 expect(copy.dart2jsHint, options.dart2jsHint); 2265 expect(copy.dart2jsHint, options.dart2jsHint);
2267 expect(copy.enableAsync, options.enableAsync);
2268 expect(copy.enableDeferredLoading, options.enableDeferredLoading); 2266 expect(copy.enableDeferredLoading, options.enableDeferredLoading);
2269 expect(copy.enableEnum, options.enableEnum); 2267 expect(copy.enableEnum, options.enableEnum);
2270 expect(copy.generateSdkErrors, options.generateSdkErrors); 2268 expect(copy.generateSdkErrors, options.generateSdkErrors);
2271 expect(copy.hint, options.hint); 2269 expect(copy.hint, options.hint);
2272 expect(copy.incremental, options.incremental); 2270 expect(copy.incremental, options.incremental);
2273 expect(copy.preserveComments, options.preserveComments); 2271 expect(copy.preserveComments, options.preserveComments);
2274 } 2272 }
2275 } 2273 }
2276 2274
2277 void test_getAnalyzeAngular() { 2275 void test_getAnalyzeAngular() {
(...skipping 25 matching lines...) Expand all
2303 expect(options.cacheSize, value); 2301 expect(options.cacheSize, value);
2304 } 2302 }
2305 2303
2306 void test_getDart2jsHint() { 2304 void test_getDart2jsHint() {
2307 AnalysisOptionsImpl options = new AnalysisOptionsImpl(); 2305 AnalysisOptionsImpl options = new AnalysisOptionsImpl();
2308 bool value = !options.dart2jsHint; 2306 bool value = !options.dart2jsHint;
2309 options.dart2jsHint = value; 2307 options.dart2jsHint = value;
2310 expect(options.dart2jsHint, value); 2308 expect(options.dart2jsHint, value);
2311 } 2309 }
2312 2310
2313 void test_getEnableAsync() {
2314 AnalysisOptionsImpl options = new AnalysisOptionsImpl();
2315 expect(options.enableAsync, AnalysisOptionsImpl.DEFAULT_ENABLE_ASYNC);
2316 bool value = !options.enableAsync;
2317 options.enableAsync = value;
2318 expect(options.enableAsync, value);
2319 }
2320
2321 void test_getEnableDeferredLoading() { 2311 void test_getEnableDeferredLoading() {
2322 AnalysisOptionsImpl options = new AnalysisOptionsImpl(); 2312 AnalysisOptionsImpl options = new AnalysisOptionsImpl();
2323 expect( 2313 expect(
2324 options.enableDeferredLoading, 2314 options.enableDeferredLoading,
2325 AnalysisOptionsImpl.DEFAULT_ENABLE_DEFERRED_LOADING); 2315 AnalysisOptionsImpl.DEFAULT_ENABLE_DEFERRED_LOADING);
2326 bool value = !options.enableDeferredLoading; 2316 bool value = !options.enableDeferredLoading;
2327 options.enableDeferredLoading = value; 2317 options.enableDeferredLoading = value;
2328 expect(options.enableDeferredLoading, value); 2318 expect(options.enableDeferredLoading, value);
2329 } 2319 }
2330 2320
(...skipping 4817 matching lines...) Expand 10 before | Expand all | Expand 10 after
7148 bool contains(Source source) => source == libB; 7138 bool contains(Source source) => source == libB;
7149 } 7139 }
7150 7140
7151 7141
7152 class _UniversalCachePartitionTest_test_setMaxCacheSize implements 7142 class _UniversalCachePartitionTest_test_setMaxCacheSize implements
7153 CacheRetentionPolicy { 7143 CacheRetentionPolicy {
7154 @override 7144 @override
7155 RetentionPriority getAstPriority(Source source, SourceEntry sourceEntry) => 7145 RetentionPriority getAstPriority(Source source, SourceEntry sourceEntry) =>
7156 RetentionPriority.LOW; 7146 RetentionPriority.LOW;
7157 } 7147 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698