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

Unified Diff: pkg/unittest/test/matchers_test.dart

Issue 15755005: Change output of string equality match failures. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 7 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 | « pkg/unittest/lib/src/core_matchers.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/unittest/test/matchers_test.dart
===================================================================
--- pkg/unittest/test/matchers_test.dart (revision 23039)
+++ pkg/unittest/test/matchers_test.dart (working copy)
@@ -506,7 +506,8 @@
shouldPass(a, containsPair('foo', 'bar'));
shouldFail(a, containsPair('foo', 'ba'),
"Expected: contains pair 'foo' => 'ba' "
- "But: contains key 'foo' but with value was 'bar'. "
+ "But: Strings are not equal. Both strings start the same, "
+ "but the given value also has the following trailing characters: r. "
"Actual: {'foo': 'bar'}");
shouldFail(a, containsPair('fo', 'bar'),
"Expected: contains pair 'fo' => 'bar' "
@@ -598,7 +599,8 @@
var completer = new Completer();
completer.completeError('X');
shouldFail(completer.future, throwsA(equals('Y')),
- "Expected: 'Y' But: was 'X'.",
+ "Expected: 'Y' But: Strings are not equal. "
+ "Expected: Y But was: XX ^ Differ at position 0. Actual: 'X'",
Siggi Cherem (dart-lang) 2013/05/22 23:09:42 I assume some \n and spaces are trimmed here? it w
isAsync: true);
});
});
« no previous file with comments | « pkg/unittest/lib/src/core_matchers.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698