@Test
public void getHeadCommitIRINotSetTest() {

    // Setup:
    thrown.expect(IllegalStateException.class);
    thrown.expectMessage("Branch " + LONE_BRANCH_IRI + " does not have a head Commit set");
    Branch branch = branchFactory.createNew(LONE_BRANCH_IRI);
    service.getHeadCommitIRI(branch);
}