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

Side by Side Diff: tests/lib/i18n/intl_message_test.dart

Issue 10807096: Add date formatting and parsing code. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 years, 5 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, 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 5
6 #library('intl_message_test'); 6 #library('intl_message_test');
7 7
8 #import('../../../lib/i18n/intl.dart'); 8 #import('../../../lib/i18n/intl.dart');
9 #import('../../../lib/i18n/intl_message.dart'); 9 #import('../../../lib/i18n/intl_message.dart');
10 #import('../../../lib/unittest/unittest.dart'); 10 #import('../../../lib/unittest/unittest.dart');
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
69 }); 69 });
70 70
71 test('Message with object parameter', () { 71 test('Message with object parameter', () {
72 hello(person) => intl.message( 72 hello(person) => intl.message(
73 "Hello, my name is ${person.firstName} ${person.lastName}.", 73 "Hello, my name is ${person.firstName} ${person.lastName}.",
74 desc: "States a person's name.", 74 desc: "States a person's name.",
75 examples: {'first': 'Ford', 'last' : 'Prefect'}); 75 examples: {'first': 'Ford', 'last' : 'Prefect'});
76 var ford = new Person('Ford', 'Prefect'); 76 var ford = new Person('Ford', 'Prefect');
77 expect(hello(ford), equals('Hello, my name is Ford Prefect.')); 77 expect(hello(ford), equals('Hello, my name is Ford Prefect.'));
78 }); 78 });
79
80 test('Set locale', (){
81 var de = new Intl('de_DE');
82 expect(de.locale,equals('de_DE'));
Emily Fortuna 2012/07/31 05:52:53 space after , why put this in intl_message_test?
Alan Knight 2012/08/03 23:02:15 Done. Moved to a separate intl_test.dart.
83 });
79 } 84 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698