Skip to content

Commit

Permalink
Delete ExcludeFromStyleCop (#9247)
Browse files Browse the repository at this point in the history
Context
The ExcludeFromStyleCop is not effective anymore. Even if it was, it's not clear why we would want to exclude so many files from style checks.

Changes Made
Deleted all occurrences of <ExcludeFromStyleCop>true</ExcludeFromStyleCop> from project files.

Testing
Build (CLI and VS).
  • Loading branch information
ladipro authored and MichalPavlik committed Oct 17, 2023
1 parent 56cb905 commit 48b97b2
Show file tree
Hide file tree
Showing 5 changed files with 252 additions and 803 deletions.
36 changes: 9 additions & 27 deletions src/Build.OM.UnitTests/Microsoft.Build.Engine.OM.UnitTests.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -36,21 +36,11 @@
<Compile Include="..\Shared\EncodingStringWriter.cs">
<Link>EncodingStringWriter.cs</Link>
</Compile>
<Compile Include="..\Shared\UnitTests\ObjectModelHelpers.cs">
<ExcludeFromStyleCop>true</ExcludeFromStyleCop>
</Compile>
<Compile Include="..\Shared\UnitTests\MockLogger.cs">
<ExcludeFromStyleCop>true</ExcludeFromStyleCop>
</Compile>
<Compile Include="..\Shared\ErrorUtilities.cs">
<ExcludeFromStyleCop>true</ExcludeFromStyleCop>
</Compile>
<Compile Include="..\Shared\FileDelegates.cs">
<ExcludeFromStyleCop>true</ExcludeFromStyleCop>
</Compile>
<Compile Include="..\Shared\ResourceUtilities.cs">
<ExcludeFromStyleCop>true</ExcludeFromStyleCop>
</Compile>
<Compile Include="..\Shared\UnitTests\ObjectModelHelpers.cs" />
<Compile Include="..\Shared\UnitTests\MockLogger.cs" />
<Compile Include="..\Shared\ErrorUtilities.cs" />
<Compile Include="..\Shared\FileDelegates.cs" />
<Compile Include="..\Shared\ResourceUtilities.cs" />
<Compile Include="..\Shared\UnitTests\EngineTestEnvironment.cs">
<Link>EngineTestEnvironment.cs</Link>
</Compile>
Expand All @@ -61,18 +51,10 @@
<Link>BuildEnvironmentHelper.cs</Link>
</Compile>
<Compile Include="..\Shared\TempFileUtilities.cs" />
<Compile Include="..\Shared\FileUtilities.cs">
<ExcludeFromStyleCop>true</ExcludeFromStyleCop>
</Compile>
<Compile Include="..\Shared\EscapingUtilities.cs">
<ExcludeFromStyleCop>true</ExcludeFromStyleCop>
</Compile>
<Compile Include="..\Shared\FileUtilitiesRegex.cs">
<ExcludeFromStyleCop>true</ExcludeFromStyleCop>
</Compile>
<Compile Include="..\Shared\ExceptionHandling.cs">
<ExcludeFromStyleCop>true</ExcludeFromStyleCop>
</Compile>
<Compile Include="..\Shared\FileUtilities.cs" />
<Compile Include="..\Shared\EscapingUtilities.cs" />
<Compile Include="..\Shared\FileUtilitiesRegex.cs" />
<Compile Include="..\Shared\ExceptionHandling.cs" />
<Compile Include="..\Shared\UnitTests\TestData\GlobbingTestData.cs">
<Link>TestData\GlobbingTestData.cs</Link>
</Compile>
Expand Down
59 changes: 14 additions & 45 deletions src/Build.UnitTests/Microsoft.Build.Engine.UnitTests.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -50,65 +50,34 @@
</ItemGroup>

<ItemGroup>
<Compile Include="..\Shared\UnitTests\BuildEventArgsExtension.cs">
<!-- Extension methods -->
<ExcludeFromStyleCop>true</ExcludeFromStyleCop>
</Compile>
<Compile Include="..\Shared\UnitTests\EscapingUtilities_Tests.cs">
<ExcludeFromStyleCop>true</ExcludeFromStyleCop>
</Compile>
<Compile Include="..\Shared\UnitTests\ErrorUtilities_Tests.cs">
<ExcludeFromStyleCop>true</ExcludeFromStyleCop>
</Compile>
<Compile Include="..\Shared\UnitTests\PrintLineDebugger_Tests.cs">
<ExcludeFromStyleCop>true</ExcludeFromStyleCop>
</Compile>
<Compile Include="..\Shared\UnitTests\FileUtilities_Tests.cs">
<ExcludeFromStyleCop>true</ExcludeFromStyleCop>
</Compile>
<Compile Include="..\Shared\UnitTests\FileMatcher_Tests.cs">
<ExcludeFromStyleCop>true</ExcludeFromStyleCop>
</Compile>
<Compile Include="..\Shared\UnitTests\MockEngine.cs">
<ExcludeFromStyleCop>true</ExcludeFromStyleCop>
</Compile>
<Compile Include="..\Shared\UnitTests\MockLogger.cs">
<ExcludeFromStyleCop>true</ExcludeFromStyleCop>
</Compile>
<Compile Include="..\Shared\UnitTests\ResourceUtilities_Tests.cs">
<ExcludeFromStyleCop>true</ExcludeFromStyleCop>
</Compile>
<Compile Include="..\Shared\UnitTests\BuildEventArgsExtension.cs" />
<Compile Include="..\Shared\UnitTests\EscapingUtilities_Tests.cs" />
<Compile Include="..\Shared\UnitTests\ErrorUtilities_Tests.cs" />
<Compile Include="..\Shared\UnitTests\PrintLineDebugger_Tests.cs" />
<Compile Include="..\Shared\UnitTests\FileUtilities_Tests.cs" />
<Compile Include="..\Shared\UnitTests\FileMatcher_Tests.cs" />
<Compile Include="..\Shared\UnitTests\MockEngine.cs" />
<Compile Include="..\Shared\UnitTests\MockLogger.cs" />
<Compile Include="..\Shared\UnitTests\ResourceUtilities_Tests.cs" />
<Compile Include="..\UnitTests.Shared\EnvironmentProvider.cs" />
<Compile Include="..\UnitTests.Shared\RunnerUtilities.cs">
<ExcludeFromStyleCop>true</ExcludeFromStyleCop>
</Compile>
<Compile Include="..\UnitTests.Shared\RunnerUtilities.cs" />
<Compile Include="..\UnitTests.Shared\DriveMapping.cs" />
<Compile Include="..\UnitTests.Shared\DummyMappedDrive.cs" />
<Compile Include="..\UnitTests.Shared\DummyMappedDriveUtils.cs" />
<Compile Include="..\Shared\UnitTests\StreamHelpers.cs">
<ExcludeFromStyleCop>true</ExcludeFromStyleCop>
</Compile>
<Compile Include="..\Shared\UnitTests\StreamHelpers.cs" />
<Compile Include="..\Shared\UnitTests\EngineTestEnvironment.cs">
<Link>EngineTestEnvironment.cs</Link>
</Compile>
<Compile Include="..\Shared\UnitTests\TestEnvironment.cs">
<Link>TestEnvironment.cs</Link>
</Compile>
<Compile Include="..\Shared\UnitTests\TypeLoader_Tests.cs">
<ExcludeFromStyleCop>true</ExcludeFromStyleCop>
</Compile>
<Compile Include="..\Shared\UnitTests\TypeLoader_Dependencies_Tests.cs">
<ExcludeFromStyleCop>true</ExcludeFromStyleCop>
</Compile>
<Compile Include="..\Shared\UnitTests\TypeLoader_Tests.cs" />
<Compile Include="..\Shared\UnitTests\TypeLoader_Dependencies_Tests.cs" />
<Compile Include="..\Shared\UnitTests\XmakeAttributes_Tests.cs">
<ExcludeFromStyleCop>true</ExcludeFromStyleCop>
<Link>XmakeAttributes_Tests.cs</Link>
</Compile>
<Compile Include="..\Shared\UnitTests\XmlUtilities_Tests.cs">
<ExcludeFromStyleCop>true</ExcludeFromStyleCop>
</Compile>
<Compile Include="..\Shared\UnitTests\XmlUtilities_Tests.cs" />
<Compile Include="..\Shared\UnitTests\AssemblyNameEx_Tests.cs">
<ExcludeFromStyleCop>true</ExcludeFromStyleCop>
<Link>AssemblyNameEx_Tests.cs</Link>
</Compile>
<Compile Include="..\Shared\UnitTests\TaskParameter_Tests.cs">
Expand Down
Loading

0 comments on commit 48b97b2

Please sign in to comment.