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

Unified Diff: utils/tests/pub/pub_tests.dart

Issue 10154010: test rename overhaul: step 3 _tests.dart => _test.dart (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 8 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 side-by-side diff with in-line comments
Download patch
Index: utils/tests/pub/pub_tests.dart
diff --git a/utils/tests/pub/pub_tests.dart b/utils/tests/pub/pub_tests.dart
deleted file mode 100644
index 91e95d4d4a4bd33aeeb0b69826a8e59f8ba6952a..0000000000000000000000000000000000000000
--- a/utils/tests/pub/pub_tests.dart
+++ /dev/null
@@ -1,114 +0,0 @@
-// Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
-// for details. All rights reserved. Use of this source code is governed by a
-// BSD-style license that can be found in the LICENSE file.
-
-#library('pub_tests');
-
-#import('dart:io');
-
-#import('test_pub.dart');
-#import('../../../lib/unittest/unittest.dart');
-
-main() {
- group('running pub with no command', () {
- testPub('displays usage',
- args: [],
- output: """
- Pub is a package manager for Dart.
-
- Usage:
-
- pub command [arguments]
-
- The commands are:
-
- list print the contents of repositories
- update update a package's dependencies
- version print Pub version
-
- Use "pub help [command]" for more information about a command.
- """);
- });
-
- group('an unknown command', () {
- testPub('displays an error message',
- args: ['quylthulg'],
- output: '''
- Unknown command "quylthulg".
- Run "pub help" to see available commands.
- ''',
- exitCode: 64);
- });
-
- group('pub list', listCommand);
- group('pub update', updateCommand);
- group('pub version', versionCommand);
-}
-
-listCommand() {
- group('cache', () {
- testPub('treats an empty directory as a package',
- cache: [
- dir('apple'),
- dir('banana'),
- dir('cherry')
- ],
- args: ['list', 'cache'],
- output: '''
- apple
- banana
- cherry
- ''');
- });
-}
-
-updateCommand() {
- testPub('adds a dependent package',
- cache: [
- dir('foo', [
- file('foo.dart', 'main() => "foo";')
- ])
- ],
- app: dir('myapp', [
- file('pubspec', 'foo')
- ]),
- args: ['update'],
- expectedPackageDir: [
- dir('foo', [
- file('foo.dart', 'main() => "foo";')
- ])
- ],
- output: '');
-
- testPub('adds a transitively dependent package',
- cache: [
- dir('foo', [
- file('foo.dart', 'main() => "foo";'),
- file('pubspec', 'bar')
- ]),
- dir('bar', [
- file('bar.dart', 'main() => "bar";'),
- ])
- ],
- app: dir('myapp', [
- file('pubspec', 'foo')
- ]),
- args: ['update'],
- expectedPackageDir: [
- dir('foo', [
- file('foo.dart', 'main() => "foo";')
- ]),
- dir('bar', [
- file('bar.dart', 'main() => "bar";'),
- ])
- ],
- output: '');
-}
-
-versionCommand() {
- testPub('displays the current version',
- args: ['version'],
- output: '''
- Pub 0.0.0
- ''');
-}

Powered by Google App Engine
This is Rietveld 408576698