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

Side by Side Diff: pkg/analyzer/test/src/dart/analysis/driver_test.dart

Issue 2678193002: Not task based analysis. (Closed)
Patch Set: Created 3 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
OLDNEW
1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2016, 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 library analyzer.test.driver; 5 library analyzer.test.driver;
6 6
7 import 'dart:async'; 7 import 'dart:async';
8 import 'dart:convert'; 8 import 'dart:convert';
9 9
10 import 'package:analyzer/dart/ast/ast.dart'; 10 import 'package:analyzer/dart/ast/ast.dart';
(...skipping 2037 matching lines...) Expand 10 before | Expand all | Expand 10 after
2048 return variable; 2048 return variable;
2049 } 2049 }
2050 } 2050 }
2051 } 2051 }
2052 } 2052 }
2053 fail('Cannot find the top-level variable $name in\n$unit'); 2053 fail('Cannot find the top-level variable $name in\n$unit');
2054 return null; 2054 return null;
2055 } 2055 }
2056 2056
2057 String _getTopLevelVarType(CompilationUnit unit, String name) { 2057 String _getTopLevelVarType(CompilationUnit unit, String name) {
2058 VariableDeclaration variable = _getTopLevelVar(unit, name);
2058 return resolutionMap 2059 return resolutionMap
2059 .elementDeclaredByVariableDeclaration(_getTopLevelVar(unit, name)) 2060 .elementDeclaredByVariableDeclaration(variable)
2060 .type 2061 .type
2061 .toString(); 2062 .toString();
2062 } 2063 }
2063 2064
2064 /** 2065 /**
2065 * Return the [provider] specific path for the given Posix [path]. 2066 * Return the [provider] specific path for the given Posix [path].
2066 */ 2067 */
2067 String _p(String path) => provider.convertPath(path); 2068 String _p(String path) => provider.convertPath(path);
2068 2069
2069 static String _md5(String content) { 2070 static String _md5(String content) {
2070 return hex.encode(md5.convert(UTF8.encode(content)).bytes); 2071 return hex.encode(md5.convert(UTF8.encode(content)).bytes);
2071 } 2072 }
2072 } 2073 }
2073 2074
2074 class _SourceMock extends TypedMock implements Source {} 2075 class _SourceMock extends TypedMock implements Source {}
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698