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

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

Issue 1761583002: Regularize some errors thrown by SecureContext. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: 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
« no previous file with comments | « runtime/bin/secure_socket.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/standalone/io/security_context_argument_test.dart
diff --git a/tests/standalone/io/security_context_argument_test.dart b/tests/standalone/io/security_context_argument_test.dart
index e5332ac0e70c6c14ef9785aa21d899aefa248f6f..6e9ddcfa3075d2fca853641be962fe21c878b7e7 100644
--- a/tests/standalone/io/security_context_argument_test.dart
+++ b/tests/standalone/io/security_context_argument_test.dart
@@ -44,10 +44,10 @@ void testUsePrivateKeyArguments() {
tlsException);
Expect.throws(() => c.setClientAuthorities(
localFile('certificates/server_key.p12')),
- argumentError);
+ tlsException);
Expect.throws(() => c.setClientAuthorities(
localFile('certificates/server_key.p12'), password: "iHackSites"),
- argumentError);
+ tlsException);
// File does not exist
Expect.throws(() => c.usePrivateKey(
@@ -97,7 +97,7 @@ void testUsePrivateKeyArguments() {
tlsException);
Expect.throws(() => c.setTrustedCertificatesBytes([]), tlsException);
Expect.throws(() => c.useCertificateChainBytes([]), tlsException);
- Expect.throws(() => c.setClientAuthoritiesBytes([]), argumentError);
+ Expect.throws(() => c.setClientAuthoritiesBytes([]), tlsException);
// Malformed PEM certs.
Expect.throws(() => c.usePrivateKey(
@@ -115,7 +115,7 @@ void testUsePrivateKeyArguments() {
tlsException);
Expect.throws(() => c.setClientAuthorities(
localFile('certificates/client_authority_malformed.pem')),
- argumentError);
+ tlsException);
c.usePrivateKey(
localFile('certificates/server_key.pem'), password: "dartdart");
« no previous file with comments | « runtime/bin/secure_socket.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698