Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -225,4 +225,7 @@
<data name="RemoveDuplicateTestMethodAttributeFix" xml:space="preserve">
<value>Remove duplicate TestMethod attribute</value>
</data>
</root>
<data name="UseAsyncAssertionFix" xml:space="preserve">
<value>Use async assertion</value>
</data>
</root>
440 changes: 440 additions & 0 deletions src/Analyzers/MSTest.Analyzers.CodeFixes/PreferAsyncAssertionFixer.cs

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,11 @@
<target state="translated">Transformovat přepsání Execute na ExecuteAsync</target>
<note />
</trans-unit>
<trans-unit id="UseAsyncAssertionFix">
<source>Use async assertion</source>
<target state="new">Use async assertion</target>
<note />
</trans-unit>
<trans-unit id="UseAttributeOnTestMethodFix">
<source>Add '[TestMethod]'</source>
<target state="translated">Přidat [TestMethod]</target>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,11 @@
<target state="translated">Transformieren Sie die Überschreibung von „Execute“ in „ExecuteAsync“.</target>
<note />
</trans-unit>
<trans-unit id="UseAsyncAssertionFix">
<source>Use async assertion</source>
<target state="new">Use async assertion</target>
<note />
</trans-unit>
<trans-unit id="UseAttributeOnTestMethodFix">
<source>Add '[TestMethod]'</source>
<target state="translated">„[TestMethod]“ hinzufügen</target>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,11 @@
<target state="translated">Transformar la invalidación "Execute" en "ExecuteAsync"</target>
<note />
</trans-unit>
<trans-unit id="UseAsyncAssertionFix">
<source>Use async assertion</source>
<target state="new">Use async assertion</target>
<note />
</trans-unit>
<trans-unit id="UseAttributeOnTestMethodFix">
<source>Add '[TestMethod]'</source>
<target state="translated">Agregar '[TestMethod]'</target>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,11 @@
<target state="translated">Transformer la redéfinition « Execute » en « ExecuteAsync »</target>
<note />
</trans-unit>
<trans-unit id="UseAsyncAssertionFix">
<source>Use async assertion</source>
<target state="new">Use async assertion</target>
<note />
</trans-unit>
<trans-unit id="UseAttributeOnTestMethodFix">
<source>Add '[TestMethod]'</source>
<target state="translated">Ajouter « [TestMethod] »</target>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,11 @@
<target state="translated">Trasformare l'override di 'Execute' in 'ExecuteAsync'</target>
<note />
</trans-unit>
<trans-unit id="UseAsyncAssertionFix">
<source>Use async assertion</source>
<target state="new">Use async assertion</target>
<note />
</trans-unit>
<trans-unit id="UseAttributeOnTestMethodFix">
<source>Add '[TestMethod]'</source>
<target state="translated">Aggiungi '[TestMethod]'</target>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,11 @@
<target state="translated">'Execute' オーバーライドを 'ExecuteAsync' に変換する</target>
<note />
</trans-unit>
<trans-unit id="UseAsyncAssertionFix">
<source>Use async assertion</source>
<target state="new">Use async assertion</target>
<note />
</trans-unit>
<trans-unit id="UseAttributeOnTestMethodFix">
<source>Add '[TestMethod]'</source>
<target state="translated">'[TestMethod]' の追加</target>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,11 @@
<target state="translated">'Execute' 재정의를 'ExecuteAsync'로 변환</target>
<note />
</trans-unit>
<trans-unit id="UseAsyncAssertionFix">
<source>Use async assertion</source>
<target state="new">Use async assertion</target>
<note />
</trans-unit>
<trans-unit id="UseAttributeOnTestMethodFix">
<source>Add '[TestMethod]'</source>
<target state="translated">'[TestMethod]' 추가</target>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,11 @@
<target state="translated">Zmień zastąpienie „Execute” na „ExecuteAsync”</target>
<note />
</trans-unit>
<trans-unit id="UseAsyncAssertionFix">
<source>Use async assertion</source>
<target state="new">Use async assertion</target>
<note />
</trans-unit>
<trans-unit id="UseAttributeOnTestMethodFix">
<source>Add '[TestMethod]'</source>
<target state="translated">Dodaj „[TestMethod]”</target>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,11 @@
<target state="translated">Transformar a substituição "Execute" em "ExecuteAsync"</target>
<note />
</trans-unit>
<trans-unit id="UseAsyncAssertionFix">
<source>Use async assertion</source>
<target state="new">Use async assertion</target>
<note />
</trans-unit>
<trans-unit id="UseAttributeOnTestMethodFix">
<source>Add '[TestMethod]'</source>
<target state="translated">Adicionar ''[TestMethod]"</target>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,11 @@
<target state="translated">Преобразовать переопределение "Execute" в "ExecuteAsync"</target>
<note />
</trans-unit>
<trans-unit id="UseAsyncAssertionFix">
<source>Use async assertion</source>
<target state="new">Use async assertion</target>
<note />
</trans-unit>
<trans-unit id="UseAttributeOnTestMethodFix">
<source>Add '[TestMethod]'</source>
<target state="translated">Добавить "[TestMethod]"</target>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,11 @@
<target state="translated">'Execute' geçersiz kılmasını 'ExecuteAsync' olarak dönüştür</target>
<note />
</trans-unit>
<trans-unit id="UseAsyncAssertionFix">
<source>Use async assertion</source>
<target state="new">Use async assertion</target>
<note />
</trans-unit>
<trans-unit id="UseAttributeOnTestMethodFix">
<source>Add '[TestMethod]'</source>
<target state="translated">'[TestMethod]' ekle</target>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,11 @@
<target state="translated">将‘Execute’重写为‘ExecuteAsync’</target>
<note />
</trans-unit>
<trans-unit id="UseAsyncAssertionFix">
<source>Use async assertion</source>
<target state="new">Use async assertion</target>
<note />
</trans-unit>
<trans-unit id="UseAttributeOnTestMethodFix">
<source>Add '[TestMethod]'</source>
<target state="translated">添加“[TestMethod]”</target>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,11 @@
<target state="translated">將 'Execute' 覆寫改為 'ExecuteAsync'</target>
<note />
</trans-unit>
<trans-unit id="UseAsyncAssertionFix">
<source>Use async assertion</source>
<target state="new">Use async assertion</target>
<note />
</trans-unit>
<trans-unit id="UseAttributeOnTestMethodFix">
<source>Add '[TestMethod]'</source>
<target state="translated">新增 '[TestMethod]'</target>
Expand Down
6 changes: 6 additions & 0 deletions src/Analyzers/MSTest.Analyzers/AnalyzerReleases.Unshipped.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,8 @@
; Unshipped analyzer release
; https://github.com/dotnet/roslyn-analyzers/blob/main/src/Microsoft.CodeAnalysis.Analyzers/ReleaseTrackingAnalyzers.Help.md

### New Rules

Rule ID | Category | Severity | Notes
--------|----------|----------|-------
MSTEST0064 | Usage | Info | PreferAsyncAssertionAnalyzer, [Documentation](https://learn.microsoft.com/dotnet/core/testing/mstest-analyzers/mstest0064)
1 change: 1 addition & 0 deletions src/Analyzers/MSTest.Analyzers/Helpers/DiagnosticIds.cs
Original file line number Diff line number Diff line change
Expand Up @@ -68,4 +68,5 @@ internal static class DiagnosticIds
public const string UseOSConditionAttributeInsteadOfRuntimeCheckRuleId = "MSTEST0061";
public const string AvoidOutRefTestMethodParametersRuleId = "MSTEST0062";
public const string TestClassConstructorShouldBeValidRuleId = "MSTEST0063";
public const string PreferAsyncAssertionRuleId = "MSTEST0064";
}
Loading