Skip to content
Snippets Groups Projects
Commit 107ab9ee authored by ale's avatar ale
Browse files

add explicit auth failure test

parent c57b574a
Branches
Tags
No related merge requests found
......@@ -59,6 +59,17 @@ TEST_F(AuthClientTest, AuthOK) {
<< ", server=" << server;
}
TEST_F(AuthClientTest, AuthFail) {
int result;
result = auth_client_set_certificate(ac, ssl_ca, ssl_cert, ssl_key);
EXPECT_EQ(AC_OK, result) << "set_certificate() error: " << auth_client_strerror(result);
result = auth_client_authenticate(ac, "user", "bad_password", NULL, "127.0.0.1");
EXPECT_NE(AC_OK, result) << "authenticate() didn't fail"
<< ", server=" << server;
}
TEST_F(AuthClientTest, SSLFailsWithBadCertificate) {
int result;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment