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

Unified Diff: client/testing/unittest/shared.dart

Issue 9365023: add string-equals to unittest, fix implementation in expect.dart (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: '' Created 8 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 | « no previous file | corelib/src/expect.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: client/testing/unittest/shared.dart
diff --git a/client/testing/unittest/shared.dart b/client/testing/unittest/shared.dart
index c6faa4aec568a3a12b4015a75b5c607077e22458..4f633785614714142337438112251665d409ab61 100644
--- a/client/testing/unittest/shared.dart
+++ b/client/testing/unittest/shared.dart
@@ -263,7 +263,11 @@ class Expectation {
/** Asserts that the value is equivalent to [expected]. */
void equals(expected) {
- Expect.equals(expected, _value);
+ if (_value is String && expected is String) {
+ Expect.stringEquals(expected, _value);
+ } else {
+ Expect.equals(expected, _value);
+ }
}
/**
« no previous file with comments | « no previous file | corelib/src/expect.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698