FortifySensor implements Sensor { @Override public boolean shouldExecuteOnProject(Project project) { return this.configuration.isActive(this.fileSystem.languages()) && this.report.exist(); } FortifySensor(
    FortifySensorConfiguration configuration,
    ResourcePerspectives resourcePerspectives,
    FileSystem fileSystem,
    ActiveRules activeRules); @Override boolean shouldExecuteOnProject(Project project); @Override void analyse(Project project, SensorContext context); @Override String toString();  }
@Test public void shouldExecuteOnProjectTest() { when(this.configuration.isActive(anyListOf(String.class))).thenReturn(false); assertThat(this.sensor.shouldExecuteOnProject(null)).isFalse(); when(this.configuration.isActive(anyListOf(String.class))).thenReturn(true); assertThat(this.sensor.shouldExecuteOnProject(null)).isFalse(); }