protected CoverageDecorator(
     CSharpConfiguration configuration,
     MicrosoftWindowsEnvironment microsoftWindowsEnvironment,
     ResourceHelper resourceHelper) {
   this.microsoftWindowsEnvironment = microsoftWindowsEnvironment;
   this.vsSolution = microsoftWindowsEnvironment.getCurrentSolution();
   String[] exclusions = configuration.getStringArray(GallioConstants.COVERAGE_EXCLUDES_KEY);
   if (exclusions == null) {
     this.excludedAssemblies = Collections.EMPTY_SET;
   } else {
     this.excludedAssemblies = Sets.newHashSet(exclusions);
   }
   this.resourceHelper = resourceHelper;
 }
  @BeforeClass
  public static void init() {
    aRule = Rule.create("gendarme", "Rule", "Rule").setSeverity(RulePriority.BLOCKER);
    aFileIMoney = new org.sonar.api.resources.File("IMoney");
    aFileMoney = new org.sonar.api.resources.File("Money");

    env = mock(MicrosoftWindowsEnvironment.class);
    VisualStudioSolution solution = mock(VisualStudioSolution.class);
    when(env.getCurrentSolution()).thenReturn(solution);
    VisualStudioProject vsProject = mock(VisualStudioProject.class);
    when(solution.getProjectFromSonarProject(any(Project.class))).thenReturn(vsProject);
    when(solution.getProject(any(File.class))).thenReturn(vsProject);

    project = mock(Project.class);
    ProjectFileSystem fileSystem = mock(ProjectFileSystem.class);
    when(fileSystem.getSourceDirs()).thenReturn(Lists.newArrayList(new File("C:\\Sonar\\Example")));
    when(project.getFileSystem()).thenReturn(fileSystem);
    resourcesBridge = createFakeBridge();

    resourceHelper = mock(ResourceHelper.class);
    when(resourceHelper.isResourceInProject(any(Resource.class), eq(project))).thenReturn(true);
  }