when(mockRefParse.call()).thenReturn(ref);
List<ObjectId> oIds = Arrays.asList(ObjectId.forString("Object 1"),
ObjectId.forString("Object 2"));
when(mockIndexDb.lookUp(anyString())).thenReturn(oIds);
when(mockCommands.stagingDatabase()).thenReturn(mockIndexDb);
RevParse command = new RevParse();
command.setContext(mockCommands);
exception.expect(IllegalArgumentException.class);
command.setRefSpec(commitId1.toString().substring(0, commitId1.toString().length() - 2))