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

Unified Diff: tests/standalone/io/file_test.dart

Issue 11263040: Make String.charCodes a getter. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Update status files with co19 issue number. Created 8 years, 2 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 | « tests/standalone/io/file_system_links_test.dart ('k') | tests/standalone/io/http_basic_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/standalone/io/file_test.dart
diff --git a/tests/standalone/io/file_test.dart b/tests/standalone/io/file_test.dart
index 70d7f799b7b55b1553b91a308a27d9422cfdbe0b..4fd426a75a74d90346bc7b051c07c3ca94ae5c6a 100644
--- a/tests/standalone/io/file_test.dart
+++ b/tests/standalone/io/file_test.dart
@@ -398,7 +398,7 @@ class FileTest {
File file = new File(filename);
file.createSync();
Expect.isTrue(new File(filename).existsSync());
- List<int> buffer = content.charCodes();
+ List<int> buffer = content.charCodes;
RandomAccessFile openedFile = file.openSync(FileMode.WRITE);
openedFile.writeListSync(buffer, 0, buffer.length);
openedFile.closeSync();
@@ -421,7 +421,7 @@ class FileTest {
String filename = tempDirectory.path.concat("/outstream_write_append");
File file = new File(filename);
file.createSync();
- List<int> buffer = content.charCodes();
+ List<int> buffer = content.charCodes;
OutputStream outStream = file.openOutputStream();
outStream.write(buffer);
outStream.onNoPendingWrites = () {
@@ -458,7 +458,7 @@ class FileTest {
String filename = tempDirectory.path.concat("/outstream_write_string");
File file = new File(filename);
file.createSync();
- List<int> buffer = content.charCodes();
+ List<int> buffer = content.charCodes;
OutputStream outStream = file.openOutputStream();
outStream.writeString("abcdABCD");
outStream.writeString("abcdABCD", Encoding.UTF_8);
@@ -1045,11 +1045,11 @@ class FileTest {
f.readAsText(Encoding.UTF_8).then((text) {
Expect.equals(6, text.length);
var expected = [955, 120, 46, 32, 120, 10];
- Expect.listEquals(expected, text.charCodes());
+ Expect.listEquals(expected, text.charCodes);
f.readAsText(Encoding.ISO_8859_1).then((text) {
Expect.equals(7, text.length);
var expected = [206, 187, 120, 46, 32, 120, 10];
- Expect.listEquals(expected, text.charCodes());
+ Expect.listEquals(expected, text.charCodes);
var readAsTextFuture = f.readAsText(Encoding.ASCII);
readAsTextFuture.then((text) {
Expect.fail("Non-ascii char should cause error");
@@ -1086,12 +1086,12 @@ class FileTest {
text = new File(name).readAsTextSync();
Expect.equals(6, text.length);
var expected = [955, 120, 46, 32, 120, 10];
- Expect.listEquals(expected, text.charCodes());
+ Expect.listEquals(expected, text.charCodes);
Expect.throws(() { new File(name).readAsTextSync(Encoding.ASCII); });
text = new File(name).readAsTextSync(Encoding.ISO_8859_1);
expected = [206, 187, 120, 46, 32, 120, 10];
Expect.equals(7, text.length);
- Expect.listEquals(expected, text.charCodes());
+ Expect.listEquals(expected, text.charCodes);
}
static void testReadAsTextSyncEmptyFile() {
« no previous file with comments | « tests/standalone/io/file_system_links_test.dart ('k') | tests/standalone/io/http_basic_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698