GenerateSplitPointsFromSample implements
        Operation,
        InputOutput<Iterable<? extends T>, List<T>>,
        MultiInput<T> { @Override public ValidationResult validate() { final ValidationResult result = InputOutput.super.validate(); if (null != numSplits && numSplits < 1) { result.addError("numSplits must be null or greater than 0"); } return result; }  @Override ValidationResult validate(); @Override Iterable<? extends T> getInput(); @Override void setInput(final Iterable<? extends T> input); @Override TypeReference<List<T>> getOutputTypeReference(); @Override GenerateSplitPointsFromSample<T> shallowClone(); @Override Map<String, String> getOptions(); @Override void setOptions(final Map<String, String> options); Integer getNumSplits(); void setNumSplits(final Integer numSplits);  }
@Test public void shouldFailValidationIfNumSplitsIsLessThan1() { final GenerateSplitPointsFromSample op = new GenerateSplitPointsFromSample.Builder<>() .numSplits(0) .build(); final ValidationResult result = op.validate(); assertFalse(result.isValid()); assertTrue(result.getErrorString().contains("numSplits must be null or greater than 0"), result.getErrorString()); }