public async Task MainModuleType_InterfaceType_GoodCase() { var test = @" namespace GpxViewer.Modules.Testing.Interface.Messages { public class {|#0:TestMessage|} { //... } }"; await CSharpAnalyzerVerifier <ModuleTypeAccessAnalyzer> .VerifyAnalyzerAsync(test); }
public async Task MainModuleType_LogicType_GoodCase() { var test = @" namespace GpxViewer.Modules.Testing.Logic { internal class {|#0:TestLogicClass|} { //... } }"; await CSharpAnalyzerVerifier <ModuleTypeAccessAnalyzer> .VerifyAnalyzerAsync(test); }
public async Task MainModuleType_LogicType_BadCase() { var test = @" namespace GpxViewer.Modules.Testing.Logic { public class {|#0:TestLogicClass|} { //... } }"; var expected = CSharpAnalyzerVerifier <ModuleTypeAccessAnalyzer> .Diagnostic(ModuleTypeAccessAnalyzer.DIAGNOSTIC_ID) .WithLocation(0) .WithArguments("TestLogicClass", "Public", "Internal"); await CSharpAnalyzerVerifier <ModuleTypeAccessAnalyzer> .VerifyAnalyzerAsync(test, expected); }
public async Task VerifyAnalyzerAsync() { await CSharpAnalyzerVerifier <SourceAnalyzer> .VerifyAnalyzerAsync(_analyzer.Source); }
public async Task VerifyAnalyzerAsync() { _analyzerAssertions.AddDiagnosticResult(_diagnosticResult); await CSharpAnalyzerVerifier <SourceAnalyzer> .VerifyAnalyzerAsync(_analyzerAssertions.Subject.Source, _analyzerAssertions.DiagnosticResults.ToArray()); }