### Question:
FirstWorkingReporter implements Reporter { @Override public void notTheSame(byte[] oldValue, File fileForVerification, byte[] newValue, File fileForApproval) { for (Reporter other : others) { if (other.canApprove(fileForApproval)) { other.notTheSame(oldValue, fileForVerification, newValue, fileForApproval); return; } } throw new IllegalStateException("There is no reporter that can approve " + fileForVerification); } FirstWorkingReporter(Reporter... others); @Override void notTheSame(byte[] oldValue, File fileForVerification, byte[] newValue, File fileForApproval); @Override void approveNew(byte[] value, File fileForApproval, File fileForVerification); @Override boolean canApprove(File fileForApproval);  }### Answer:
@Test(expected = IllegalStateException.class) public void shouldThrowAnExceptionIfNooneCanApproveNotTheSame() throws Exception { new FirstWorkingReporter(first, second, third).notTheSame(null, null, null, null); }