Class WebACRecipesIT
- java.lang.Object
-
- org.fcrepo.integration.http.api.AbstractResourceIT
-
- org.fcrepo.integration.auth.webac.WebACRecipesIT
-
@TestExecutionListeners(listeners=org.fcrepo.integration.http.api.TestIsolationExecutionListener.class, mergeMode=MERGE_WITH_DEFAULTS) public class WebACRecipesIT extends org.fcrepo.integration.http.api.AbstractResourceIT- Since:
- September 4, 2015
- Author:
- Peter Eichman, whikloj
-
-
Field Summary
Fields Modifier and Type Field Description org.junit.contrib.java.lang.system.RestoreSystemPropertiesrestoreSystemProperties
-
Constructor Summary
Constructors Constructor Description WebACRecipesIT()
-
Method Summary
-
Methods inherited from class org.fcrepo.integration.http.api.AbstractResourceIT
addTxTo, assertConstrainedByPresent, assertDeleted, assertNoLinkHeader, assertNotDeleted, assertNotFound, checkForLinkHeader, confirmResponseBodyNTriplesAreEqual, createClient, createClient, createDatastream, createDatastream, createObject, createObject, createObjectAndClose, createObjectAndClose, createTransaction, decodeDigestHeader, deleteObjMethod, execute, executeAndClose, executeWithBasicAuth, getBean, getBean, getContentLocation, getContentType, getContentType, getDataset, getDataset, getDSDescMethod, getDSMethod, getDSMethod, getEtag, getEtag, getEtag, getExternalContentLinkHeader, getHeader, getLinkHeaders, getLinkHeaders, getLocation, getLocation, getModel, getModel, getModel, getModel, getObjMethod, getOriginalResourceUri, getRandomUniqueId, getStatus, getStatus, getTTLThatUpdatesServerManagedTriples, headerValues, headObjMethod, patchObjMethod, postObjMethod, postObjMethod, preferLink, putDSMethod, putDSMethod, putObjMethod, putObjMethod, restartContainer, setDescriptionProperty, setLogger, setProperty, setProperty, streamModel
-
-
-
-
Field Detail
-
restoreSystemProperties
public final org.junit.contrib.java.lang.system.RestoreSystemProperties restoreSystemProperties
-
-
Constructor Detail
-
WebACRecipesIT
public WebACRecipesIT()
-
-
Method Detail
-
setup
public void setup()
-
scenario1
public void scenario1() throws IOException
- Throws:
IOException
-
scenario2
public void scenario2() throws IOException
- Throws:
IOException
-
scenario3
public void scenario3() throws IOException
- Throws:
IOException
-
scenario4
public void scenario4() throws IOException
- Throws:
IOException
-
scenario5
public void scenario5() throws IOException
- Throws:
IOException
-
scenario9
public void scenario9() throws IOException
- Throws:
IOException
-
scenario18Test1
public void scenario18Test1() throws IOException
Test cases to verify authorization with only acl:Append mode configured in the acl authorization of an resource. Tests: 1. Deny(403) on GET. 2. Allow(204) on PATCH. 3. Deny(403) on DELETE. 4. Deny(403) on PATCH with SPARQL DELETE statements. 5. Allow(400) on PATCH with empty SPARQL content. 6. Deny(403) on PATCH with non-SPARQL content.- Throws:
IOException- thrown from injestObj() or *ObjMethod() calls
-
scenario18Test2
public void scenario18Test2() throws IOException
Test cases to verify authorization with acl:Read and acl:Append modes configured in the acl authorization of an resource. Tests: 1. Allow(200) on GET. 2. Allow(204) on PATCH. 3. Deny(403) on DELETE.- Throws:
IOException- thrown from called functions within this function
-
scenario18Test3
public void scenario18Test3() throws IOException
Test cases to verify authorization with acl:Read, acl:Append and acl:Write modes configured in the acl authorization of an resource. Tests: 1. Allow(200) on GET. 2. Allow(204) on PATCH. 3. Allow(204) on DELETE.- Throws:
IOException- from functions called from this function
-
testAccessToRoot
public void testAccessToRoot() throws IOException
- Throws:
IOException
-
scenario21TestACLNotForInheritance
public void scenario21TestACLNotForInheritance() throws IOException
- Throws:
IOException
-
scenario22TestACLAuthorizationNotForInheritance
public void scenario22TestACLAuthorizationNotForInheritance() throws IOException
- Throws:
IOException
-
testAccessToBinary
public void testAccessToBinary() throws IOException
- Throws:
IOException
-
testAccessToVersionedResources
public void testAccessToVersionedResources() throws IOException
- Throws:
IOException
-
testDelegatedUserAccess
public void testDelegatedUserAccess() throws IOException
- Throws:
IOException
-
testAccessByUriToVersionedResources
public void testAccessByUriToVersionedResources() throws IOException
- Throws:
IOException
-
testAgentAsUri
public void testAgentAsUri() throws IOException
- Throws:
IOException
-
testRegisterNamespace
public void testRegisterNamespace() throws IOException
- Throws:
IOException
-
testRegisterNodeType
public void testRegisterNodeType() throws IOException
- Throws:
IOException
-
testDeletePropertyAsUser
public void testDeletePropertyAsUser() throws IOException
- Throws:
IOException
-
testHeadWithReadOnlyUser
public void testHeadWithReadOnlyUser() throws IOException
- Throws:
IOException
-
testOptionsWithReadOnlyUser
public void testOptionsWithReadOnlyUser() throws IOException
- Throws:
IOException
-
testControl
public void testControl() throws IOException
- Throws:
IOException
-
testAppendOnlyToContainer
public void testAppendOnlyToContainer() throws IOException
- Throws:
IOException
-
testAppendOnlyToBinary
public void testAppendOnlyToBinary() throws IOException
- Throws:
IOException
-
testFoafAgent
public void testFoafAgent() throws IOException
- Throws:
IOException
-
testAuthenticatedAgent
public void testAuthenticatedAgent() throws IOException
- Throws:
IOException
-
testAgentGroupWithHashUris
public void testAgentGroupWithHashUris() throws Exception
- Throws:
Exception
-
testAgentGroupWithMembersAsURIs
public void testAgentGroupWithMembersAsURIs() throws Exception
- Throws:
Exception
-
testAgentGroup
public void testAgentGroup() throws Exception
- Throws:
Exception
-
testAclAppendPermissions
public void testAclAppendPermissions() throws Exception
- Throws:
Exception
-
testCreateAclWithAccessToClassForBinary
public void testCreateAclWithAccessToClassForBinary() throws Exception
- Throws:
Exception
-
testIndirectRelationshipForbidden
public void testIndirectRelationshipForbidden() throws IOException
- Throws:
IOException
-
testIndirectRelationshipOK
public void testIndirectRelationshipOK() throws IOException
- Throws:
IOException
-
testDirectRelationshipForbidden
public void testDirectRelationshipForbidden() throws IOException
- Throws:
IOException
-
testDirectRelationshipsOk
public void testDirectRelationshipsOk() throws IOException
- Throws:
IOException
-
testSameInTransaction
public void testSameInTransaction() throws Exception
- Throws:
Exception
-
testBinaryAndDescriptionAllowed
public void testBinaryAndDescriptionAllowed() throws Exception
- Throws:
Exception
-
testRequestWithEmptyPath
public void testRequestWithEmptyPath() throws Exception
- Throws:
Exception
-
testGetWithEmbeddedResourcesOk
public void testGetWithEmbeddedResourcesOk() throws Exception
- Throws:
Exception
-
testGetWithEmbeddedResourceDenied
public void testGetWithEmbeddedResourceDenied() throws Exception
- Throws:
Exception
-
testDeepDeleteAllowed
public void testDeepDeleteAllowed() throws Exception
- Throws:
Exception
-
testDeepDeleteFailed
public void testDeepDeleteFailed() throws Exception
- Throws:
Exception
-
testTransactionExceptions
public void testTransactionExceptions() throws Exception
- Throws:
Exception
-
testAuthenticatedUserCanCreateTransaction
public void testAuthenticatedUserCanCreateTransaction()
-
testAlterAclWithPatch
public void testAlterAclWithPatch() throws IOException
- Throws:
IOException
-
testAlterAclWithPut
public void testAlterAclWithPut() throws IOException
- Throws:
IOException
-
testDeleteTombstone
public void testDeleteTombstone() throws IOException
- Throws:
IOException
-
-