    @Test
    void should_not_report_invalid_violation() {


        // given
        final RuleViolation pmdViolation = violation();
        final Report report = report(pmdViolation);
        when(executor.execute()).thenReturn(report);
        when(report.iterator()).thenReturn(Iterators.forArray(pmdViolation));

        // when
        pmdSensor.execute(sensorContext);

        // then
        verify(pmdViolationRecorder, never()).saveViolation(any(RuleViolation.class), eq(sensorContext));
        verifyZeroInteractions(sensorContext);
    }