Index: tests/standalone/io/secure_server_closing_test.dart |
diff --git a/tests/standalone/io/secure_server_closing_test.dart b/tests/standalone/io/secure_server_closing_test.dart |
index 0677a41c9d517392ea049c7a4e4776c74c349e29..585e3c2a36cb9525db68f913864cd32347752c34 100644 |
--- a/tests/standalone/io/secure_server_closing_test.dart |
+++ b/tests/standalone/io/secure_server_closing_test.dart |
@@ -16,11 +16,12 @@ import "package:expect/expect.dart"; |
InternetAddress HOST; |
String localFile(path) => Platform.script.resolve(path).toFilePath(); |
+List<int> readLocalFile(path) => (new File(localFile(path))).readAsBytesSync(); |
SecurityContext serverContext = new SecurityContext() |
..useCertificateChain(localFile('certificates/server_chain.pem')) |
- ..usePrivateKey(localFile('certificates/server_key.pem'), |
- password: 'dartdart'); |
+ ..usePrivateKeyAsBytes(readLocalFile('certificates/server_key.pem'), |
+ password: 'dartdart'); |
SecurityContext clientContext = new SecurityContext() |
..setTrustedCertificates(file: localFile('certificates/trusted_certs.pem')); |