Skip to content

Commit

Permalink
feat: Add test for saving Process without Eperson
Browse files Browse the repository at this point in the history
  • Loading branch information
Roy Bruschini committed Feb 1, 2024
1 parent e36bb75 commit a49e51a
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions dspace-api/src/test/java/org/dspace/process/ProcessIT.java
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@

import static org.junit.Assert.assertFalse;
import static org.junit.Assert.assertTrue;
import static org.junit.Assert.fail;

import java.util.HashSet;
import java.util.LinkedList;
Expand Down Expand Up @@ -87,4 +88,14 @@ public void removeOneGroupTest() throws Exception {
assertFalse(isPresent);

}

@Test
public void addProcessWithNullEPersonTest() throws Exception {
try {
ProcessBuilder.createProcess(context, null, "mock-script", new LinkedList<>(),
new HashSet<>()).build();
} catch (NullPointerException e) {
fail("Should not have throw NullPointerException");
}
}
}

0 comments on commit a49e51a

Please sign in to comment.