| OLD | NEW |
| 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, 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 library message_extraction_test; | 5 library message_extraction_test; |
| 6 | 6 |
| 7 import 'package:unittest/unittest.dart'; | 7 import 'package:unittest/unittest.dart'; |
| 8 import 'dart:io'; | 8 import 'dart:io'; |
| 9 import 'dart:async'; | 9 import 'dart:async'; |
| 10 import 'package:path/path.dart' as path; | 10 import 'package:path/path.dart' as path; |
| (...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 170 verify('Alice, Bob sont allés au magasin'); | 170 verify('Alice, Bob sont allés au magasin'); |
| 171 verify('Alice est allée au magasin'); | 171 verify('Alice est allée au magasin'); |
| 172 verify('Personne n\'est allé au magasin'); | 172 verify('Personne n\'est allé au magasin'); |
| 173 verify('Bob, Bob sont allés au magasin'); | 173 verify('Bob, Bob sont allés au magasin'); |
| 174 verify('Alice, Alice sont allées au magasin'); | 174 verify('Alice, Alice sont allées au magasin'); |
| 175 verify('none'); | 175 verify('none'); |
| 176 verify('one'); | 176 verify('one'); |
| 177 verify('m'); | 177 verify('m'); |
| 178 verify('f'); | 178 verify('f'); |
| 179 verify('7 male'); | 179 verify('7 male'); |
| 180 verify('7 Canadian dollars'); |
| 181 verify('5 some currency or other.'); |
| 182 verify('1 Canadian dollar'); |
| 183 verify('2 Canadian dollars'); |
| 180 | 184 |
| 181 var fr_lines = lines.skip(1).skipWhile( | 185 var fr_lines = lines.skip(1).skipWhile( |
| 182 (line) => !line.contains('----')).toList(); | 186 (line) => !line.contains('----')).toList(); |
| 183 lineIterator = fr_lines.iterator..moveNext(); | 187 lineIterator = fr_lines.iterator..moveNext(); |
| 184 verify("Printing messages for fr"); | 188 verify("Printing messages for fr"); |
| 185 verify("Il s'agit d'un message"); | 189 verify("Il s'agit d'un message"); |
| 186 verify("Un autre message avec un seul paramètre hello"); | 190 verify("Un autre message avec un seul paramètre hello"); |
| 187 verify( | 191 verify( |
| 188 "Caractères qui doivent être échapper, par exemple barres \\ " | 192 "Caractères qui doivent être échapper, par exemple barres \\ " |
| 189 "dollars \${ (les accolades sont ok), et xml/html réservés <& et " | 193 "dollars \${ (les accolades sont ok), et xml/html réservés <& et " |
| (...skipping 23 matching lines...) Expand all Loading... |
| 213 verify('Alice, Bob étaient allés à la magasin'); | 217 verify('Alice, Bob étaient allés à la magasin'); |
| 214 verify('Alice était allée à la magasin'); | 218 verify('Alice était allée à la magasin'); |
| 215 verify('Personne n\'avait allé à la magasin'); | 219 verify('Personne n\'avait allé à la magasin'); |
| 216 verify('Bob, Bob étaient allés à la magasin'); | 220 verify('Bob, Bob étaient allés à la magasin'); |
| 217 verify('Alice, Alice étaient allées à la magasin'); | 221 verify('Alice, Alice étaient allées à la magasin'); |
| 218 verify('rien'); | 222 verify('rien'); |
| 219 verify('un'); | 223 verify('un'); |
| 220 verify('homme'); | 224 verify('homme'); |
| 221 verify('femme'); | 225 verify('femme'); |
| 222 verify('7 homme'); | 226 verify('7 homme'); |
| 227 verify('7 dollars Canadiens'); |
| 228 verify('5 certaine devise ou autre.'); |
| 229 verify('1 dollar Canadien'); |
| 230 verify('2 dollars Canadiens'); |
| 223 | 231 |
| 224 var de_lines = fr_lines.skip(1).skipWhile( | 232 var de_lines = fr_lines.skip(1).skipWhile( |
| 225 (line) => !line.contains('----')).toList(); | 233 (line) => !line.contains('----')).toList(); |
| 226 lineIterator = de_lines.iterator..moveNext(); | 234 lineIterator = de_lines.iterator..moveNext(); |
| 227 verify("Printing messages for de_DE"); | 235 verify("Printing messages for de_DE"); |
| 228 verify("Dies ist eine Nachricht"); | 236 verify("Dies ist eine Nachricht"); |
| 229 verify("Eine weitere Meldung mit dem Parameter hello"); | 237 verify("Eine weitere Meldung mit dem Parameter hello"); |
| 230 verify( | 238 verify( |
| 231 "Zeichen, die Flucht benötigen, zB Schrägstriche \\ Dollar " | 239 "Zeichen, die Flucht benötigen, zB Schrägstriche \\ Dollar " |
| 232 "\${ (geschweiften Klammern sind ok) und xml reservierte Zeichen <& und " | 240 "\${ (geschweiften Klammern sind ok) und xml reservierte Zeichen <& und " |
| (...skipping 23 matching lines...) Expand all Loading... |
| 256 verify('Alice, Bob gingen zum magasin'); | 264 verify('Alice, Bob gingen zum magasin'); |
| 257 verify('Alice ging in dem magasin'); | 265 verify('Alice ging in dem magasin'); |
| 258 verify('Niemand ging zu magasin'); | 266 verify('Niemand ging zu magasin'); |
| 259 verify('Bob, Bob gingen zum magasin'); | 267 verify('Bob, Bob gingen zum magasin'); |
| 260 verify('Alice, Alice gingen zum magasin'); | 268 verify('Alice, Alice gingen zum magasin'); |
| 261 verify('Null'); | 269 verify('Null'); |
| 262 verify('ein'); | 270 verify('ein'); |
| 263 verify('Mann'); | 271 verify('Mann'); |
| 264 verify('Frau'); | 272 verify('Frau'); |
| 265 verify('7 Mann'); | 273 verify('7 Mann'); |
| 274 verify('7 Kanadischen dollar'); |
| 275 verify('5 einige Währung oder anderen.'); |
| 276 verify('1 Kanadischer dollar'); |
| 277 verify('2 Kanadischen dollar'); |
| 266 } | 278 } |
| OLD | NEW |