| OLD | NEW |
| 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 bidi_format_test; | 6 library bidi_format_test; |
| 7 | 7 |
| 8 import 'package:intl/intl.dart'; | 8 import '../lib/intl.dart'; |
| 9 import 'package:unittest/unittest.dart'; | 9 import '../../../pkg/unittest/lib/unittest.dart'; |
| 10 | 10 |
| 11 /** | 11 /** |
| 12 * Tests the bidirectional text formatting library. | 12 * Tests the bidirectional text formatting library. |
| 13 */ | 13 */ |
| 14 main() { | 14 main() { |
| 15 var LTR = TextDirection.LTR; | 15 var LTR = TextDirection.LTR; |
| 16 var RTL = TextDirection.RTL; | 16 var RTL = TextDirection.RTL; |
| 17 var LRM = Bidi.LRM; | 17 var LRM = Bidi.LRM; |
| 18 var RLM = Bidi.RLM; | 18 var RLM = Bidi.RLM; |
| 19 var RLE = Bidi.RLE; | 19 var RLE = Bidi.RLE; |
| (...skipping 198 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 218 expect(rtlFmt.wrapWithUnicode(he, direction : TextDirection.LTR), | 218 expect(rtlFmt.wrapWithUnicode(he, direction : TextDirection.LTR), |
| 219 equals('$LRE$he$PDF$RLM')); | 219 equals('$LRE$he$PDF$RLM')); |
| 220 // Test supposed overall dir (LTR) doesn't match context dir (unknown). | 220 // Test supposed overall dir (LTR) doesn't match context dir (unknown). |
| 221 expect(unkFmt.wrapWithUnicode(he, direction : TextDirection.LTR), | 221 expect(unkFmt.wrapWithUnicode(he, direction : TextDirection.LTR), |
| 222 equals('$LRE$he$PDF')); | 222 equals('$LRE$he$PDF')); |
| 223 // Test supposed overall dir (neutral) doesn't match context dir (LTR). | 223 // Test supposed overall dir (neutral) doesn't match context dir (LTR). |
| 224 expect(ltrFmt.wrapWithUnicode(he, direction : TextDirection.UNKNOWN), | 224 expect(ltrFmt.wrapWithUnicode(he, direction : TextDirection.UNKNOWN), |
| 225 equals('$he$LRM')); | 225 equals('$he$LRM')); |
| 226 }); | 226 }); |
| 227 } | 227 } |
| OLD | NEW |