Skip to content

Commit 23dbd9e

Browse files
author
Christian Käser
committed
Use DocumentationResources in SA1643UnitTests
1 parent 1ec8763 commit 23dbd9e

1 file changed

Lines changed: 10 additions & 7 deletions

File tree

StyleCop.Analyzers/StyleCop.Analyzers.Test/DocumentationRules/SA1643UnitTests.cs

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,18 +4,21 @@
44
namespace StyleCop.Analyzers.Test.DocumentationRules
55
{
66
using System.Collections.Generic;
7+
using System.Globalization;
78
using System.Threading;
89
using System.Threading.Tasks;
910
using Microsoft.CodeAnalysis.CodeFixes;
1011
using Microsoft.CodeAnalysis.Diagnostics;
1112
using StyleCop.Analyzers.DocumentationRules;
13+
using StyleCop.Analyzers.Test.Helpers;
14+
1215
using TestHelper;
1316
using Xunit;
14-
using static StyleCop.Analyzers.DocumentationRules.SA1643DestructorSummaryDocumentationMustBeginWithStandardText;
1517

1618
/// <summary>
1719
/// This class contains unit tests for <see cref="SA1643DestructorSummaryDocumentationMustBeginWithStandardText"/>-
1820
/// </summary>
21+
[UseCulture("en-US")]
1922
public class SA1643UnitTests : CodeFixVerifier
2023
{
2124
[Fact]
@@ -37,37 +40,37 @@ public class Foo<TFoo, TBar>
3740
[Fact]
3841
public async Task TestDestructorCorrectDocumentationSimpleAsync()
3942
{
40-
await this.TestDestructorCorrectDocumentationSimpleImplAsync(DestructorStandardText[0], DestructorStandardText[1], false).ConfigureAwait(false);
43+
await this.TestDestructorCorrectDocumentationSimpleImplAsync(DocumentationResources.DestructorStandardTextFirstPart, DocumentationResources.DestructorStandardTextSecondPart, false).ConfigureAwait(false);
4144
}
4245

4346
[Fact]
4447
public async Task TestDestructorCorrectDocumentationCustomizedAsync()
4548
{
46-
await this.TestDestructorCorrectDocumentationCustomizedImplAsync(DestructorStandardText[0], DestructorStandardText[1], false).ConfigureAwait(false);
49+
await this.TestDestructorCorrectDocumentationCustomizedImplAsync(DocumentationResources.DestructorStandardTextFirstPart, DocumentationResources.DestructorStandardTextSecondPart, false).ConfigureAwait(false);
4750
}
4851

4952
[Fact]
5053
public async Task TestNonPrivateConstructorCorrectDocumentationGenericSimpleAsync()
5154
{
52-
await this.TestDestructorCorrectDocumentationSimpleImplAsync(DestructorStandardText[0], DestructorStandardText[1], true).ConfigureAwait(false);
55+
await this.TestDestructorCorrectDocumentationSimpleImplAsync(DocumentationResources.DestructorStandardTextFirstPart, DocumentationResources.DestructorStandardTextSecondPart, true).ConfigureAwait(false);
5356
}
5457

5558
[Fact]
5659
public async Task TestDestructorCorrectDocumentationGenericCustomizedAsync()
5760
{
58-
await this.TestDestructorCorrectDocumentationCustomizedImplAsync(DestructorStandardText[0], DestructorStandardText[1], true).ConfigureAwait(false);
61+
await this.TestDestructorCorrectDocumentationCustomizedImplAsync(DocumentationResources.DestructorStandardTextFirstPart, DocumentationResources.DestructorStandardTextSecondPart, true).ConfigureAwait(false);
5962
}
6063

6164
[Fact]
6265
public async Task TestDestructorMissingDocumentationAsync()
6366
{
64-
await this.TestDestructorMissingDocumentationImplAsync(DestructorStandardText[0], DestructorStandardText[1], false).ConfigureAwait(false);
67+
await this.TestDestructorMissingDocumentationImplAsync(DocumentationResources.DestructorStandardTextFirstPart, DocumentationResources.DestructorStandardTextSecondPart, false).ConfigureAwait(false);
6568
}
6669

6770
[Fact]
6871
public async Task TestDestructorMissingDocumentationGenericAsync()
6972
{
70-
await this.TestDestructorMissingDocumentationImplAsync(DestructorStandardText[0], DestructorStandardText[1], true).ConfigureAwait(false);
73+
await this.TestDestructorMissingDocumentationImplAsync(DocumentationResources.DestructorStandardTextFirstPart, DocumentationResources.DestructorStandardTextSecondPart, true).ConfigureAwait(false);
7174
}
7275

7376
protected override IEnumerable<DiagnosticAnalyzer> GetCSharpDiagnosticAnalyzers()

0 commit comments

Comments
 (0)