X-Git-Url: https://code.wpia.club/?a=blobdiff_plain;f=tests%2Forg%2Fcacert%2Fgigi%2FLoginTest.java;h=d6c6fc4941910fc1828d29cbc17abd70e67147f9;hb=9136e3e03b6881b32aada896be3241e46cbd33d9;hp=bb4e4a8ea7f7818dc885889841e55b7c1737e7a2;hpb=412719ad8098d38459a3f53165c24dde48d8b7e2;p=gigi.git diff --git a/tests/org/cacert/gigi/LoginTest.java b/tests/org/cacert/gigi/LoginTest.java index bb4e4a8e..d6c6fc49 100644 --- a/tests/org/cacert/gigi/LoginTest.java +++ b/tests/org/cacert/gigi/LoginTest.java @@ -1,10 +1,10 @@ package org.cacert.gigi; +import static org.junit.Assert.*; + import java.io.IOException; import java.net.URL; -import static org.junit.Assert.*; - import org.cacert.gigi.testUtils.ManagedTest; import org.junit.Test; @@ -25,6 +25,13 @@ public class LoginTest extends ManagedTest { assertTrue(isLoggedin(login(email, TEST_PASSWORD))); } + @Test + public void testLoginWrongPassword() throws IOException { + String email = createUniqueName() + "@testmail.org"; + createVerifiedUser("an", "bn", email, TEST_PASSWORD); + assertFalse(isLoggedin(login(email, TEST_PASSWORD + "b"))); + } + @Test public void testLogoutVerified() throws IOException { String email = createUniqueName() + "@testmail.org";