Class AuthenticationResponseCodeTest
- java.lang.Object
-
- org.apache.sling.launchpad.webapp.integrationtest.auth.AuthenticationResponseCodeTest
-
public class AuthenticationResponseCodeTest extends Object
Test of the response code from an authentication request depending on various request parameters and headers including j_validate, Ajax detection, and non-browser client detection.
-
-
Field Summary
Fields Modifier and Type Field Description org.junit.rules.TestRulelogRule
-
Constructor Summary
Constructors Constructor Description AuthenticationResponseCodeTest()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected org.apache.commons.httpclient.HttpMethodassertPostStatus(String url, int expectedStatusCode, List<org.apache.commons.httpclient.NameValuePair> postParams, List<org.apache.commons.httpclient.Header> headers, String assertMessage)voidcleanup()voidsetup()voidtestPreventLoopIncorrectFormCredentials()voidtestPreventLoopIncorrectHttpBasicCredentials()voidtestValidatingCorrectFormCredentials()voidtestValidatingCorrectHttpBasicCredentials()voidtestValidatingIncorrectCookie()voidtestValidatingIncorrectCredentials()voidtestValidatingIncorrectHttpBasicCredentials()voidtestWithNonHtmlAcceptHeaderIncorrectCredentials()voidtestWithoutAcceptHeaderIncorrectCredentials()voidtestXRequestedWithIncorrectCredentials()
-
-
-
Method Detail
-
testValidatingCorrectFormCredentials
public void testValidatingCorrectFormCredentials() throws Exception- Throws:
Exception
-
testValidatingCorrectHttpBasicCredentials
public void testValidatingCorrectHttpBasicCredentials() throws Exception- Throws:
Exception
-
testValidatingIncorrectCredentials
public void testValidatingIncorrectCredentials() throws Exception- Throws:
Exception
-
testValidatingIncorrectCookie
public void testValidatingIncorrectCookie() throws Exception- Throws:
Exception
-
testValidatingIncorrectHttpBasicCredentials
public void testValidatingIncorrectHttpBasicCredentials() throws Exception- Throws:
Exception
-
testPreventLoopIncorrectHttpBasicCredentials
public void testPreventLoopIncorrectHttpBasicCredentials() throws Exception- Throws:
Exception
-
testPreventLoopIncorrectFormCredentials
public void testPreventLoopIncorrectFormCredentials() throws Exception- Throws:
Exception
-
testXRequestedWithIncorrectCredentials
public void testXRequestedWithIncorrectCredentials() throws Exception- Throws:
Exception
-
testWithoutAcceptHeaderIncorrectCredentials
public void testWithoutAcceptHeaderIncorrectCredentials() throws Exception- Throws:
Exception
-
testWithNonHtmlAcceptHeaderIncorrectCredentials
public void testWithNonHtmlAcceptHeaderIncorrectCredentials() throws Exception- Throws:
Exception
-
assertPostStatus
protected org.apache.commons.httpclient.HttpMethod assertPostStatus(String url, int expectedStatusCode, List<org.apache.commons.httpclient.NameValuePair> postParams, List<org.apache.commons.httpclient.Header> headers, String assertMessage) throws IOException
- Throws:
IOException
-
-