public static NotControllerException newWrongControllerException(OptionalInt controllerId) {
        if (controllerId.isPresent()) {
            return new NotControllerException("The active controller appears to be node " +
                    controllerId.getAsInt() + ".");
        } else {
            return new NotControllerException("No controller appears to be active.");
        }
    }
@Test
    public void testNewWrongControllerExceptionWithActiveController() {
        assertExceptionsMatch(new NotControllerException("The active controller appears to be node 1."),
            newWrongControllerException(OptionalInt.of(1)));
    }