drill-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sohami <...@git.apache.org>
Subject [GitHub] drill pull request #578: DRILL-4280: Kerberos Authentication
Date Fri, 06 Jan 2017 01:33:34 GMT
Github user sohami commented on a diff in the pull request:

    https://github.com/apache/drill/pull/578#discussion_r94864855
  
    --- Diff: exec/java-exec/src/test/java/org/apache/drill/exec/rpc/user/security/TestCustomUserAuthenticator.java
---
    @@ -56,16 +68,27 @@ public void positiveUserAuth() throws Exception {
         runTest(TEST_USER_2, TEST_USER_2_PASSWORD);
       }
     
    -
       @Test
       public void negativeUserAuth() throws Exception {
         negativeAuthHelper(TEST_USER_1, "blah.. blah..");
         negativeAuthHelper(TEST_USER_2, "blah.. blah..");
    -    negativeAuthHelper(TEST_USER_2, "");
         negativeAuthHelper("invalidUserName", "blah.. blah..");
       }
     
       @Test
    +  public void emptyPassword() throws Exception {
    +    try {
    +      runTest(TEST_USER_2, "");
    +      fail("Expected an exception.");
    +    } catch (RpcException e) {
    +      final String exMsg = e.getMessage();
    +      assertThat(exMsg, containsString("Insufficient credentials"));
    --- End diff --
    
    We should check the "cause" rather than message string since that can change over time
? Same in negativeAuthHelper.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

Mime
View raw message