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

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

Issue 12262056: Clean up some warnings and deprecated calls. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « utils/tests/pub/test_pub.dart ('k') | utils/tests/pub/version_solver_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: utils/tests/pub/validator_test.dart
diff --git a/utils/tests/pub/validator_test.dart b/utils/tests/pub/validator_test.dart
index b64f1311dc68fadd64cf3bc8e67be0d2b5637707..ab67f7713e25bf4e7f345575b9d16b6d1a263ea0 100644
--- a/utils/tests/pub/validator_test.dart
+++ b/utils/tests/pub/validator_test.dart
@@ -133,9 +133,9 @@ main() {
});
integration('has "authors" instead of "author"', () {
- var package = package("test_pkg", "1.0.0");
- package["authors"] = [package.remove("author")];
- dir(appPath, [pubspec(package)]).scheduleCreate();
+ var pkg = package("test_pkg", "1.0.0");
+ pkg["authors"] = [pkg.remove("author")];
+ dir(appPath, [pubspec(pkg)]).scheduleCreate();
expectNoValidationError(pubspecField);
});
@@ -206,67 +206,67 @@ main() {
setUp(scheduleNormalPackage);
integration('is missing the "homepage" field', () {
- var package = package("test_pkg", "1.0.0");
- package.remove("homepage");
- dir(appPath, [pubspec(package)]).scheduleCreate();
+ var pkg = package("test_pkg", "1.0.0");
+ pkg.remove("homepage");
+ dir(appPath, [pubspec(pkg)]).scheduleCreate();
expectValidationError(pubspecField);
});
integration('is missing the "description" field', () {
- var package = package("test_pkg", "1.0.0");
- package.remove("description");
- dir(appPath, [pubspec(package)]).scheduleCreate();
+ var pkg = package("test_pkg", "1.0.0");
+ pkg.remove("description");
+ dir(appPath, [pubspec(pkg)]).scheduleCreate();
expectValidationError(pubspecField);
});
integration('is missing the "author" field', () {
- var package = package("test_pkg", "1.0.0");
- package.remove("author");
- dir(appPath, [pubspec(package)]).scheduleCreate();
+ var pkg = package("test_pkg", "1.0.0");
+ pkg.remove("author");
+ dir(appPath, [pubspec(pkg)]).scheduleCreate();
expectValidationError(pubspecField);
});
integration('has a single author without an email', () {
- var package = package("test_pkg", "1.0.0");
- package["author"] = "Nathan Weizenbaum";
- dir(appPath, [pubspec(package)]).scheduleCreate();
+ var pkg = package("test_pkg", "1.0.0");
+ pkg["author"] = "Nathan Weizenbaum";
+ dir(appPath, [pubspec(pkg)]).scheduleCreate();
expectValidationWarning(pubspecField);
});
integration('has one of several authors without an email', () {
- var package = package("test_pkg", "1.0.0");
- package.remove("author");
- package["authors"] = [
+ var pkg = package("test_pkg", "1.0.0");
+ pkg.remove("author");
+ pkg["authors"] = [
"Bob Nystrom <rnystrom@google.com>",
"Nathan Weizenbaum",
"John Messerly <jmesserly@google.com>"
];
- dir(appPath, [pubspec(package)]).scheduleCreate();
+ dir(appPath, [pubspec(pkg)]).scheduleCreate();
expectValidationWarning(pubspecField);
});
integration('has a single author without a name', () {
- var package = package("test_pkg", "1.0.0");
- package["author"] = "<nweiz@google.com>";
- dir(appPath, [pubspec(package)]).scheduleCreate();
+ var pkg = package("test_pkg", "1.0.0");
+ pkg["author"] = "<nweiz@google.com>";
+ dir(appPath, [pubspec(pkg)]).scheduleCreate();
expectValidationWarning(pubspecField);
});
integration('has one of several authors without a name', () {
- var package = package("test_pkg", "1.0.0");
- package.remove("author");
- package["authors"] = [
+ var pkg = package("test_pkg", "1.0.0");
+ pkg.remove("author");
+ pkg["authors"] = [
"Bob Nystrom <rnystrom@google.com>",
"<nweiz@google.com>",
"John Messerly <jmesserly@google.com>"
];
- dir(appPath, [pubspec(package)]).scheduleCreate();
+ dir(appPath, [pubspec(pkg)]).scheduleCreate();
expectValidationWarning(pubspecField);
});
« no previous file with comments | « utils/tests/pub/test_pub.dart ('k') | utils/tests/pub/version_solver_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698