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

Side by Side Diff: pkg/analysis_server/test/services/correction/util_test.dart

Issue 2394683006: Switch analysis_server to use 'package:test'. (Closed)
Patch Set: Created 4 years, 2 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 test.services.correction.util; 5 library test.services.correction.util;
6 6
7 import 'package:analysis_server/plugin/protocol/protocol.dart'; 7 import 'package:analysis_server/plugin/protocol/protocol.dart';
8 import 'package:analysis_server/src/services/correction/strings.dart'; 8 import 'package:analysis_server/src/services/correction/strings.dart';
9 import 'package:analysis_server/src/services/correction/util.dart'; 9 import 'package:analysis_server/src/services/correction/util.dart';
10 import 'package:analyzer/dart/element/element.dart'; 10 import 'package:analyzer/dart/element/element.dart';
11 import 'package:analyzer/src/generated/source.dart'; 11 import 'package:analyzer/src/generated/source.dart';
12 import 'package:test/test.dart';
12 import 'package:test_reflective_loader/test_reflective_loader.dart'; 13 import 'package:test_reflective_loader/test_reflective_loader.dart';
13 import 'package:unittest/unittest.dart';
14 14
15 import '../../abstract_single_unit.dart'; 15 import '../../abstract_single_unit.dart';
16 import '../../utils.dart'; 16 import '../../utils.dart';
17 17
18 main() { 18 main() {
19 initializeTestEnvironment(); 19 initializeTestEnvironment();
20 defineReflectiveTests(UtilTest); 20 defineReflectiveSuite(() {
21 defineReflectiveTests(UtilTest);
22 });
21 } 23 }
22 24
23 @reflectiveTest 25 @reflectiveTest
24 class UtilTest extends AbstractSingleUnitTest { 26 class UtilTest extends AbstractSingleUnitTest {
25 test_addLibraryImports_dart_hasImports_between() { 27 test_addLibraryImports_dart_hasImports_between() {
26 resolveTestUnit(''' 28 resolveTestUnit('''
27 import 'dart:async'; 29 import 'dart:async';
28 import 'dart:math'; 30 import 'dart:math';
29 '''); 31 ''');
30 LibraryElement newLibrary = _getDartLibrary('dart:collection'); 32 LibraryElement newLibrary = _getDartLibrary('dart:collection');
(...skipping 253 matching lines...) Expand 10 before | Expand all | Expand 10 after
284 @override 286 @override
285 final String fullName; 287 final String fullName;
286 288
287 @override 289 @override
288 final Uri uri; 290 final Uri uri;
289 291
290 _SourceMock(this.fullName, this.uri); 292 _SourceMock(this.fullName, this.uri);
291 293
292 noSuchMethod(Invocation invocation) => super.noSuchMethod(invocation); 294 noSuchMethod(Invocation invocation) => super.noSuchMethod(invocation);
293 } 295 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698