diff --git a/dspace-api/src/test/java/org/dspace/access/status/AccessStatusServiceTest.java b/dspace-api/src/test/java/org/dspace/access/status/AccessStatusServiceTest.java index 87127f9cf8fd..f6cdcf5bad56 100644 --- a/dspace-api/src/test/java/org/dspace/access/status/AccessStatusServiceTest.java +++ b/dspace-api/src/test/java/org/dspace/access/status/AccessStatusServiceTest.java @@ -120,6 +120,10 @@ public void destroy() { @Test public void testGetAccessStatus() throws Exception { + context.turnOffAuthorisationSystem(); + itemService.addMetadata(context, item, "datacite", "rights", null, Item.ANY, "openaccess"); + itemService.update(context, item); + context.restoreAuthSystemState(); String status = accessStatusService.getAccessStatus(context, item); assertNotEquals("testGetAccessStatus 0", status, DefaultAccessStatusHelper.UNKNOWN); }