@MockPolicy(value=SharedSetUp.class) @PowerMockIgnore(value={"javax.crypto.*","javax.management.*"}) public class AdminSvcSpec_auth_2 extends Object
| Modifier and Type | Field and Description |
|---|---|
private javax.ws.rs.container.AsyncResponse |
asyncResponseMock |
private Lot49Config |
configMock |
private ServiceRunner |
serviceRunnerMock |
private AdminSvc |
svc |
| Constructor and Description |
|---|
AdminSvcSpec_auth_2() |
| Modifier and Type | Method and Description |
|---|---|
private void |
configMocks(String host,
String baseUrl) |
void |
negativeFlow_returnsFalseIfNotLocalhostAndBadAuthCookie() |
void |
negativeFlow_returnsFalseIfNotLocalhostAndNullAuthCookie() |
void |
negativeFlow_throwsExceptionIfBaseUrlIsIncorrect() |
void |
positiveFlow_returnsTrueIfLocalhost() |
void |
positiveFlow_returnsTrueIfNotLocalhostAndGoodAuthCookie() |
void |
setUp() |
private void |
testAuthIfBaseUrlIsCorrect(String host,
String authCookie,
boolean expectedReturnValue) |
private ServiceRunner serviceRunnerMock
private Lot49Config configMock
private javax.ws.rs.container.AsyncResponse asyncResponseMock
private AdminSvc svc
private void configMocks(String host, String baseUrl) throws Exception
Exceptionpublic void positiveFlow_returnsTrueIfLocalhost()
throws Exception
Exceptionpublic void positiveFlow_returnsTrueIfNotLocalhostAndGoodAuthCookie()
throws Exception
Exceptionpublic void negativeFlow_returnsFalseIfNotLocalhostAndBadAuthCookie()
throws Exception
Exceptionpublic void negativeFlow_returnsFalseIfNotLocalhostAndNullAuthCookie()
throws Exception
Exceptionpublic void negativeFlow_throwsExceptionIfBaseUrlIsIncorrect()
throws Exception
Exception