Skip to content

Commit e0ee7b2

Browse files
authored
Merge pull request #3491 from bjornhellander/feature/test11
Added a new test project for c# 11
2 parents 5143909 + 6dc6195 commit e0ee7b2

File tree

268 files changed

+3481
-45
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

268 files changed

+3481
-45
lines changed

StyleCop.Analyzers/Directory.Build.props

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@
4747
<PackageReference Include="AsyncUsageAnalyzers" Version="1.0.0-alpha003" PrivateAssets="all" />
4848
<PackageReference Include="DotNetAnalyzers.DocumentationAnalyzers" Version="1.0.0-beta.46" PrivateAssets="all" />
4949
<PackageReference Include="StyleCop.Analyzers" Version="1.2.0-beta.304" PrivateAssets="all" />
50-
<PackageReference Include="Microsoft.CodeAnalysis.Analyzers" Version="3.3.2" PrivateAssets="all" />
50+
<PackageReference Include="Microsoft.CodeAnalysis.Analyzers" Version="3.3.3" PrivateAssets="all" />
5151
<PackageReference Include="Microsoft.CodeAnalysis.CSharp.CodeStyle" Version="4.0.1" PrivateAssets="all" />
5252
</ItemGroup>
5353

StyleCop.Analyzers/StyleCop.Analyzers.CodeFixes/DocumentationRules/FileHeaderCodeFixProvider.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -449,12 +449,12 @@ private static SyntaxTriviaList RemoveHeaderDecorationLines(SyntaxTriviaList tri
449449
for (int i = 0; i < trivia.Count; i++)
450450
{
451451
var triviaLine = trivia[i];
452-
if (triviaLine.Kind() == SyntaxKind.SingleLineCommentTrivia && triviaLine.ToFullString().Contains(settings.DocumentationRules.HeaderDecoration))
452+
if (triviaLine.IsKind(SyntaxKind.SingleLineCommentTrivia) && triviaLine.ToFullString().Contains(settings.DocumentationRules.HeaderDecoration))
453453
{
454454
decorationRemovalList.Add(i);
455455

456456
// also remove the line break
457-
if (i + 1 < trivia.Count && trivia[i + 1].Kind() == SyntaxKind.EndOfLineTrivia)
457+
if (i + 1 < trivia.Count && trivia[i + 1].IsKind(SyntaxKind.EndOfLineTrivia))
458458
{
459459
decorationRemovalList.Add(i + 1);
460460
}

StyleCop.Analyzers/StyleCop.Analyzers.CodeFixes/Properties/AssemblyInfo.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,4 +19,5 @@
1919
[assembly: InternalsVisibleTo("StyleCop.Analyzers.Test.CSharp8, PublicKey=0024000004800000940000000602000000240000525341310004000001000100c36d40d996fcc95fb6a89754728616758f459026e31478ce93633b3e27a4af416f103aa3d7a9e7998f829f8715cc1240d30724fd662042550fa71357b19562622424267e9e4640c403edbe64709a9ca5918128a9b9020b0db6e770d0dd1eac888869c23a835b74bde00e171984b1d1c24636cf030f0b23106e73035a2be145a6")]
2020
[assembly: InternalsVisibleTo("StyleCop.Analyzers.Test.CSharp9, PublicKey=0024000004800000940000000602000000240000525341310004000001000100c36d40d996fcc95fb6a89754728616758f459026e31478ce93633b3e27a4af416f103aa3d7a9e7998f829f8715cc1240d30724fd662042550fa71357b19562622424267e9e4640c403edbe64709a9ca5918128a9b9020b0db6e770d0dd1eac888869c23a835b74bde00e171984b1d1c24636cf030f0b23106e73035a2be145a6")]
2121
[assembly: InternalsVisibleTo("StyleCop.Analyzers.Test.CSharp10, PublicKey=0024000004800000940000000602000000240000525341310004000001000100c36d40d996fcc95fb6a89754728616758f459026e31478ce93633b3e27a4af416f103aa3d7a9e7998f829f8715cc1240d30724fd662042550fa71357b19562622424267e9e4640c403edbe64709a9ca5918128a9b9020b0db6e770d0dd1eac888869c23a835b74bde00e171984b1d1c24636cf030f0b23106e73035a2be145a6")]
22+
[assembly: InternalsVisibleTo("StyleCop.Analyzers.Test.CSharp11, PublicKey=0024000004800000940000000602000000240000525341310004000001000100c36d40d996fcc95fb6a89754728616758f459026e31478ce93633b3e27a4af416f103aa3d7a9e7998f829f8715cc1240d30724fd662042550fa71357b19562622424267e9e4640c403edbe64709a9ca5918128a9b9020b0db6e770d0dd1eac888869c23a835b74bde00e171984b1d1c24636cf030f0b23106e73035a2be145a6")]
2223
[assembly: InternalsVisibleTo("StyleCopTester, PublicKey=0024000004800000940000000602000000240000525341310004000001000100c36d40d996fcc95fb6a89754728616758f459026e31478ce93633b3e27a4af416f103aa3d7a9e7998f829f8715cc1240d30724fd662042550fa71357b19562622424267e9e4640c403edbe64709a9ca5918128a9b9020b0db6e770d0dd1eac888869c23a835b74bde00e171984b1d1c24636cf030f0b23106e73035a2be145a6")]
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
// Copyright (c) Tunnel Vision Laboratories, LLC. All Rights Reserved.
2+
// Licensed under the MIT License. See LICENSE in the project root for license information.
3+
4+
#nullable disable
5+
6+
namespace StyleCop.Analyzers.Test.CSharp11
7+
{
8+
using StyleCop.Analyzers.Test.CSharp10;
9+
10+
public class AnalyzerConfigurationTestsCSharp11 : AnalyzerConfigurationTestsCSharp10
11+
{
12+
}
13+
}
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
// Copyright (c) Tunnel Vision Laboratories, LLC. All Rights Reserved.
2+
// Licensed under the MIT License. See LICENSE in the project root for license information.
3+
4+
#nullable disable
5+
6+
namespace StyleCop.Analyzers.Test.CSharp11.DocumentationRules
7+
{
8+
using StyleCop.Analyzers.Test.CSharp10.DocumentationRules;
9+
10+
public class CSharp11InheritdocCodeFixProviderUnitTests : CSharp10InheritdocCodeFixProviderUnitTests
11+
{
12+
}
13+
}
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
// Copyright (c) Tunnel Vision Laboratories, LLC. All Rights Reserved.
2+
// Licensed under the MIT License. See LICENSE in the project root for license information.
3+
4+
#nullable disable
5+
6+
namespace StyleCop.Analyzers.Test.CSharp11.DocumentationRules
7+
{
8+
using StyleCop.Analyzers.Test.CSharp10.DocumentationRules;
9+
10+
public class CSharp11NoXmlFileHeaderUnitTests : CSharp10NoXmlFileHeaderUnitTests
11+
{
12+
}
13+
}
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
// Copyright (c) Tunnel Vision Laboratories, LLC. All Rights Reserved.
2+
// Licensed under the MIT License. See LICENSE in the project root for license information.
3+
4+
#nullable disable
5+
6+
namespace StyleCop.Analyzers.Test.CSharp11.DocumentationRules
7+
{
8+
using StyleCop.Analyzers.Test.CSharp10.DocumentationRules;
9+
10+
public class SA1600CSharp11UnitTests : SA1600CSharp10UnitTests
11+
{
12+
}
13+
}
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
// Copyright (c) Tunnel Vision Laboratories, LLC. All Rights Reserved.
2+
// Licensed under the MIT License. See LICENSE in the project root for license information.
3+
4+
#nullable disable
5+
6+
namespace StyleCop.Analyzers.Test.CSharp11.DocumentationRules
7+
{
8+
using StyleCop.Analyzers.Test.CSharp10.DocumentationRules;
9+
10+
public class SA1601CSharp11UnitTests : SA1601CSharp10UnitTests
11+
{
12+
}
13+
}
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
// Copyright (c) Tunnel Vision Laboratories, LLC. All Rights Reserved.
2+
// Licensed under the MIT License. See LICENSE in the project root for license information.
3+
4+
#nullable disable
5+
6+
namespace StyleCop.Analyzers.Test.CSharp11.DocumentationRules
7+
{
8+
using StyleCop.Analyzers.Test.CSharp10.DocumentationRules;
9+
10+
public class SA1602CSharp11UnitTests : SA1602CSharp10UnitTests
11+
{
12+
}
13+
}
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
// Copyright (c) Tunnel Vision Laboratories, LLC. All Rights Reserved.
2+
// Licensed under the MIT License. See LICENSE in the project root for license information.
3+
4+
#nullable disable
5+
6+
namespace StyleCop.Analyzers.Test.CSharp11.DocumentationRules
7+
{
8+
using StyleCop.Analyzers.Test.CSharp10.DocumentationRules;
9+
10+
public class SA1603CSharp11UnitTests : SA1603CSharp10UnitTests
11+
{
12+
}
13+
}

0 commit comments

Comments
 (0)