@Test
public void should_run_code_narc_with_multiple_files() throws IOException {

  addFileWithContent("src/sample.groovy", "package source\nclass SourceFile1 {\n}");
  addFileWithContent("src/foo/bar/qix/sample.groovy", "package source\nclass SourceFile1 {\n}");
  ActiveRulesBuilder activeRulesBuilder = new ActiveRulesBuilder();
  activeRulesBuilder = activateRule(activeRulesBuilder, "org.codenarc.rule.basic.EmptyClassRule", "EmptyClass");
  sensorContextTester.setActiveRules(activeRulesBuilder.build());
  ActiveRule activeRule = mock(ActiveRule.class);
  when(activeRule.getRuleKey()).thenReturn("org.codenarc.rule.basic.EmptyClassRule");
  when(profile.getActiveRulesByRepository(CodeNarcRulesDefinition.REPOSITORY_KEY)).thenReturn(Arrays.asList(activeRule));
  sensor.execute(sensorContextTester);
  assertThat(sensorContextTester.allIssues()).hasSize(2);
}