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

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

Issue 1665433002: Adds SecurityContext.setTrustedCertificatesBytes (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Adds MemBIOScope Created 4 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 side-by-side diff with in-line comments
Download patch
Index: tests/standalone/io/secure_unauthorized_client.dart
diff --git a/tests/standalone/io/secure_unauthorized_client.dart b/tests/standalone/io/secure_unauthorized_client.dart
index 8677bec0e96c39920b8946b8fc0f9d4c10152d20..19e3e6a8b42440f57cce712ba1f36e47d144f995 100644
--- a/tests/standalone/io/secure_unauthorized_client.dart
+++ b/tests/standalone/io/secure_unauthorized_client.dart
@@ -9,9 +9,10 @@ import "dart:async";
import "dart:io";
String localFile(path) => Platform.script.resolve(path).toFilePath();
+List<int> readLocalFile(path) => (new File(localFile(path))).readAsBytesSync();
SecurityContext clientContext = new SecurityContext()
- ..setTrustedCertificates(file: localFile('certificates/trusted_certs.pem'));
+ ..setTrustedCertificatesBytes(readLocalFile('certificates/trusted_certs.pem'));
class ExpectException implements Exception {
ExpectException(this.message);

Powered by Google App Engine
This is Rietveld 408576698