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

Side by Side Diff: pkg/intl/test/message_extraction/verify_messages.dart

Issue 165873005: Do not overwrite values on plurals/genders with the results of constant evaluation (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « pkg/intl/test/message_extraction/sample_with_messages.dart ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 library verify_messages; 1 library verify_messages;
2 2
3 import "print_to_list.dart"; 3 import "print_to_list.dart";
4 import "package:unittest/unittest.dart"; 4 import "package:unittest/unittest.dart";
5 5
6 verifyResult(ignored) { 6 verifyResult(ignored) {
7 var lineIterator; 7 var lineIterator;
8 verify(String s) { 8 verify(String s) {
9 lineIterator.moveNext(); 9 lineIterator.moveNext();
10 var value = lineIterator.current; 10 var value = lineIterator.current;
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
44 verify('Alice, Alice sont allées au magasin'); 44 verify('Alice, Alice sont allées au magasin');
45 verify('none'); 45 verify('none');
46 verify('one'); 46 verify('one');
47 verify('m'); 47 verify('m');
48 verify('f'); 48 verify('f');
49 verify('7 male'); 49 verify('7 male');
50 verify('7 Canadian dollars'); 50 verify('7 Canadian dollars');
51 verify('5 some currency or other.'); 51 verify('5 some currency or other.');
52 verify('1 Canadian dollar'); 52 verify('1 Canadian dollar');
53 verify('2 Canadian dollars'); 53 verify('2 Canadian dollars');
54 verify('1 thing:');
55 verify('2 things:');
54 56
55 var fr_lines = expanded.skip(1).skipWhile( 57 var fr_lines = expanded.skip(1).skipWhile(
56 (line) => !line.contains('----')).toList(); 58 (line) => !line.contains('----')).toList();
57 lineIterator = fr_lines.iterator..moveNext(); 59 lineIterator = fr_lines.iterator..moveNext();
58 verify("Printing messages for fr"); 60 verify("Printing messages for fr");
59 verify("Il s'agit d'un message"); 61 verify("Il s'agit d'un message");
60 verify("Un autre message avec un seul paramètre hello"); 62 verify("Un autre message avec un seul paramètre hello");
61 verify( 63 verify(
62 "Caractères qui doivent être échapper, par exemple barres \\ " 64 "Caractères qui doivent être échapper, par exemple barres \\ "
63 "dollars \${ (les accolades sont ok), et xml/html réservés <& et " 65 "dollars \${ (les accolades sont ok), et xml/html réservés <& et "
(...skipping 27 matching lines...) Expand all
91 verify('Alice, Alice étaient allées à la magasin'); 93 verify('Alice, Alice étaient allées à la magasin');
92 verify('rien'); 94 verify('rien');
93 verify('un'); 95 verify('un');
94 verify('homme'); 96 verify('homme');
95 verify('femme'); 97 verify('femme');
96 verify('7 homme'); 98 verify('7 homme');
97 verify('7 dollars Canadiens'); 99 verify('7 dollars Canadiens');
98 verify('5 certaine devise ou autre.'); 100 verify('5 certaine devise ou autre.');
99 verify('1 dollar Canadien'); 101 verify('1 dollar Canadien');
100 verify('2 dollars Canadiens'); 102 verify('2 dollars Canadiens');
103 verify('1 chose:');
104 verify('2 choses:');
101 105
102 var de_lines = fr_lines.skip(1).skipWhile( 106 var de_lines = fr_lines.skip(1).skipWhile(
103 (line) => !line.contains('----')).toList(); 107 (line) => !line.contains('----')).toList();
104 lineIterator = de_lines.iterator..moveNext(); 108 lineIterator = de_lines.iterator..moveNext();
105 verify("Printing messages for de_DE"); 109 verify("Printing messages for de_DE");
106 verify("Dies ist eine Nachricht"); 110 verify("Dies ist eine Nachricht");
107 verify("Eine weitere Meldung mit dem Parameter hello"); 111 verify("Eine weitere Meldung mit dem Parameter hello");
108 verify( 112 verify(
109 "Zeichen, die Flucht benötigen, zB Schrägstriche \\ Dollar " 113 "Zeichen, die Flucht benötigen, zB Schrägstriche \\ Dollar "
110 "\${ (geschweiften Klammern sind ok) und xml reservierte Zeichen <& und " 114 "\${ (geschweiften Klammern sind ok) und xml reservierte Zeichen <& und "
(...skipping 27 matching lines...) Expand all
138 verify('Alice, Alice gingen zum magasin'); 142 verify('Alice, Alice gingen zum magasin');
139 verify('Null'); 143 verify('Null');
140 verify('ein'); 144 verify('ein');
141 verify('Mann'); 145 verify('Mann');
142 verify('Frau'); 146 verify('Frau');
143 verify('7 Mann'); 147 verify('7 Mann');
144 verify('7 Kanadischen dollar'); 148 verify('7 Kanadischen dollar');
145 verify('5 einige Währung oder anderen.'); 149 verify('5 einige Währung oder anderen.');
146 verify('1 Kanadischer dollar'); 150 verify('1 Kanadischer dollar');
147 verify('2 Kanadischen dollar'); 151 verify('2 Kanadischen dollar');
152 verify('eins:');
153 verify('2 Dinge:');
148 } 154 }
OLDNEW
« no previous file with comments | « pkg/intl/test/message_extraction/sample_with_messages.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698