147 references to Verify
Microsoft.CodeAnalysis.CSharp.CommandLine.UnitTests (8)
CommandLineTests.cs (8)
971diags.Verify(); 979diags.Verify(); 1025diags.Verify(); 1090diags.Verify(); 1106diags.Verify(); // Now checked during emit. 1929diagnostics.Verify(); 1935diagnostics.Verify(); 1941diagnostics.Verify();
Microsoft.CodeAnalysis.CSharp.Emit2.UnitTests (2)
PDB\CSharpPDBTestBase.cs (1)
28compilation.GetDiagnostics().Where(d => d.Severity == DiagnosticSeverity.Error).Verify();
PDB\PDBUsingTests.cs (1)
1488compilation.GetDiagnostics().Where(d => d.Severity > DiagnosticSeverity.Info).Verify();
Microsoft.CodeAnalysis.CSharp.Emit3.UnitTests (2)
Semantics\PatternMatchingTests.cs (2)
4173SyntaxFactory.ParseExpression("A is B < C, D > E").GetDiagnostics().Verify(); 4180SyntaxFactory.ParseExpression("A as B < C, D > ?? string.Empty").GetDiagnostics().Verify();
Microsoft.CodeAnalysis.CSharp.Features.UnitTests (3)
EditAndContinue\Helpers\EditingTestBase.cs (3)
143tree1.GetDiagnostics().Verify(); 144tree2.GetDiagnostics().Verify(); 205tree.GetDiagnostics().Verify();
Microsoft.CodeAnalysis.CSharp.Semantic.UnitTests (2)
Semantics\ImportsTests.cs (1)
147comp.GetDiagnostics().Where(d => d.Severity == DiagnosticSeverity.Error).Verify();
Semantics\OperatorTests.cs (1)
6293CreateCompilation(text).GetDiagnostics().Where(d => d.Severity == DiagnosticSeverity.Error).Verify();
Microsoft.CodeAnalysis.CSharp.Symbol.UnitTests (3)
Compilation\CompilationAPITests.cs (2)
56tree.GetDiagnostics().Verify( 118tree.GetDiagnostics().Verify();
Compilation\SemanticModelAPITests.cs (1)
4366compilation.GetDiagnostics().Where(d => d.Severity == DiagnosticSeverity.Error).Verify();
Microsoft.CodeAnalysis.CSharp.Syntax.UnitTests (114)
Diagnostics\LineSpanDirectiveTests.cs (7)
42treeB.GetDiagnostics().Verify(); 88treeB.GetDiagnostics().Verify(); 184treeB.GetDiagnostics().Verify(); 234treeB.GetDiagnostics().Verify(); 302treeB.GetDiagnostics().Verify(); 354treeB.GetDiagnostics().Verify(); 412treeB.GetDiagnostics().Verify();
IncrementalParsing\IncrementalParsingTests.cs (3)
2784startTree.GetDiagnostics().Verify(); 2813startTree.GetDiagnostics().Verify(); 2843startTree.GetDiagnostics().Verify();
Parsing\AsyncParsingTests.cs (2)
2431UsingTree("class async { async async { get; } }").GetDiagnostics().Verify(); 2534UsingTree("interface async { async this[async i] { get; } }").GetDiagnostics().Verify();
Parsing\CrefParsingTests.cs (1)
818UsingNode("operator }}}(A{A{T}})").GetDiagnostics().Verify();
Parsing\ExpressionParsingTests.cs (8)
3836tree.GetDiagnostics().Verify(); 3926tree.GetDiagnostics().Verify(); 4017tree.GetDiagnostics().Verify(); 4104tree.GetDiagnostics().Verify(); 4198tree.GetDiagnostics().Verify(); 4501tree.GetDiagnostics().Verify(); 4592tree.GetDiagnostics().Verify(); 4685tree.GetDiagnostics().Verify();
Parsing\LocalFunctionParsingTests.cs (6)
546tree.GetDiagnostics().Verify(); 720UsingTree(code, TestOptions.Regular9).GetDiagnostics().Verify(); 806UsingTree(code, TestOptions.Regular9).GetDiagnostics().Verify(); 1182file.SyntaxTree.GetDiagnostics().Verify(); 1291file.SyntaxTree.GetDiagnostics().Verify(); 1706file.SyntaxTree.GetDiagnostics().Verify();
Parsing\ParserErrorMessageTests.cs (48)
3765tree.GetDiagnostics().Verify(); 5440tree.GetCompilationUnitRoot().GetDiagnostics().Verify(); 5443tree.GetCompilationUnitRoot().GetDiagnostics().Verify(); 5462tree.GetCompilationUnitRoot().GetDiagnostics().Verify(); 5465tree.GetCompilationUnitRoot().GetDiagnostics().Verify(); 5527tree.GetCompilationUnitRoot().GetDiagnostics().Verify(); 5530tree.GetCompilationUnitRoot().GetDiagnostics().Verify(); 5546tree.GetCompilationUnitRoot().GetDiagnostics().Verify(); 5549tree.GetCompilationUnitRoot().GetDiagnostics().Verify(); 5589tree.GetCompilationUnitRoot().GetDiagnostics().Verify(); 5592tree.GetCompilationUnitRoot().GetDiagnostics().Verify(); 5624tree.GetCompilationUnitRoot().GetDiagnostics().Verify(); 5627tree.GetCompilationUnitRoot().GetDiagnostics().Verify(); 5658tree.GetCompilationUnitRoot().GetDiagnostics().Verify(); 5661tree.GetCompilationUnitRoot().GetDiagnostics().Verify(); 5695tree.GetDiagnostics().Verify(); 5698tree.GetDiagnostics().Verify(); 5947tree.GetCompilationUnitRoot().GetDiagnostics().Verify(); 5965tree.GetCompilationUnitRoot().GetDiagnostics().Verify(); 5978tree.GetCompilationUnitRoot().GetDiagnostics().Verify(); 5986tree.GetCompilationUnitRoot().GetDiagnostics().Verify(); 6007tree.GetCompilationUnitRoot().GetDiagnostics().Verify(); 6014tree.GetCompilationUnitRoot().GetDiagnostics().Verify(); 6037tree.GetCompilationUnitRoot().GetDiagnostics().Verify(); 6050tree.GetCompilationUnitRoot().GetDiagnostics().Verify(); 6079tree.GetCompilationUnitRoot().GetDiagnostics().Verify(); 6092tree.GetCompilationUnitRoot().GetDiagnostics().Verify(); 6148SyntaxFactory.ParseSyntaxTree(text, options: CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp4)).GetDiagnostics().Verify(); 6149SyntaxFactory.ParseSyntaxTree(text, options: CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp3)).GetDiagnostics().Verify(); 6160SyntaxFactory.ParseSyntaxTree(text, options: CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp2)).GetDiagnostics().Verify(); 6161SyntaxFactory.ParseSyntaxTree(text, options: CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp1)).GetDiagnostics().Verify(); 6184SyntaxFactory.ParseSyntaxTree(text, options: CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp2)).GetDiagnostics().Verify(); 6185SyntaxFactory.ParseSyntaxTree(text, options: CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp1)).GetDiagnostics().Verify(); 6215SyntaxFactory.ParseSyntaxTree(text, options: CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp4)).GetDiagnostics().Verify(); 6216SyntaxFactory.ParseSyntaxTree(text, options: CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp3)).GetDiagnostics().Verify(); 6243SyntaxFactory.ParseSyntaxTree(text, options: CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp3)).GetDiagnostics().Verify(); 6244SyntaxFactory.ParseSyntaxTree(text, options: CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp2)).GetDiagnostics().Verify(); 6271SyntaxFactory.ParseSyntaxTree(text, options: CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp3)).GetDiagnostics().Verify(); 6272SyntaxFactory.ParseSyntaxTree(text, options: CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp2)).GetDiagnostics().Verify(); 6285SyntaxFactory.ParseSyntaxTree(text, options: TestOptions.RegularWithDocumentationComments.WithLanguageVersion(LanguageVersion.CSharp2)).GetDiagnostics().Verify(); 6304SyntaxFactory.ParseSyntaxTree(text, options: TestOptions.RegularWithDocumentationComments.WithLanguageVersion(LanguageVersion.CSharp2)).GetDiagnostics().Verify(); 6328SyntaxFactory.ParseSyntaxTree(text, options: TestOptions.RegularWithDocumentationComments.WithLanguageVersion(LanguageVersion.CSharp2)).GetDiagnostics().Verify(); 6348SyntaxFactory.ParseSyntaxTree(text, options: TestOptions.RegularWithDocumentationComments.WithLanguageVersion(LanguageVersion.CSharp2)).GetDiagnostics().Verify(); 6349SyntaxFactory.ParseSyntaxTree(text, options: TestOptions.RegularWithDocumentationComments.WithLanguageVersion(LanguageVersion.CSharp1)).GetDiagnostics().Verify(); 6380SyntaxFactory.ParseSyntaxTree(source, options: CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp2)).GetDiagnostics().Verify(); 6381SyntaxFactory.ParseSyntaxTree(source, options: CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp1)).GetDiagnostics().Verify(); 6475SyntaxFactory.ParseSyntaxTree(source, options: CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp6)).GetDiagnostics().Verify(); 6477SyntaxFactory.ParseSyntaxTree(source, options: CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp5)).GetDiagnostics().Verify();
Parsing\ParserRegressionTests.cs (1)
830actualErrors.Verify(expectedErrors);
Parsing\ParsingTests.cs (6)
61actualErrors.Verify(expectedErrors); 68actualErrors.Verify(expectedErrors); 75actualErrors.Take(1).Verify(expectedFirstError); 117actualErrors.Verify(expectedErrors); 137actualErrors.Verify(expectedErrors); 160actualErrors.Verify(expectedErrors);
Parsing\PatternParsingTests.cs (14)
302SyntaxFactory.ParseExpression("e is A<B> && e").GetDiagnostics().Verify(); 303SyntaxFactory.ParseExpression("e is A<B> || e").GetDiagnostics().Verify(); 304SyntaxFactory.ParseExpression("e is A<B> ^ e").GetDiagnostics().Verify(); 305SyntaxFactory.ParseExpression("e is A<B> | e").GetDiagnostics().Verify(); 306SyntaxFactory.ParseExpression("e is A<B> & e").GetDiagnostics().Verify(); 307SyntaxFactory.ParseExpression("e is A<B>[]").GetDiagnostics().Verify(); 308SyntaxFactory.ParseExpression("new { X = e is A<B> }").GetDiagnostics().Verify(); 309SyntaxFactory.ParseExpression("e is A<B>").GetDiagnostics().Verify(); 311SyntaxFactory.ParseExpression("(item is Dictionary<string, object>[])").GetDiagnostics().Verify(); 312SyntaxFactory.ParseExpression("A is B < C, D > [ ]").GetDiagnostics().Verify(); 313SyntaxFactory.ParseExpression("A is B < C, D > [ ] E").GetDiagnostics().Verify(); 314SyntaxFactory.ParseExpression("A < B > C").GetDiagnostics().Verify(); 320SyntaxFactory.ParseExpression("from s in a where s is string where s.Length > 1 select s").GetDiagnostics().Verify(); 321SyntaxFactory.ParseExpression("M(out int? x)").GetDiagnostics().Verify();
Parsing\RecordParsing.cs (5)
265tree.GetDiagnostics().Verify(); 309tree.GetDiagnostics().Verify(); 331tree.GetDiagnostics().Verify(); 334tree.GetDiagnostics().Verify(); 1218tree.GetDiagnostics().Verify();
Parsing\StatementParsingTests.cs (3)
3462tree.GetDiagnostics(root).Verify( 3507tree.GetDiagnostics().Verify(); 3532tree.GetDiagnostics(tree.GetRoot()).Verify(
Parsing\TopLevelStatementsParsingTests.cs (1)
1624tree.GetDiagnostics().Verify();
Syntax\LambdaUtilitiesTests.cs (1)
44compilation.GetDiagnostics().Where(d => d.Severity == DiagnosticSeverity.Error).Verify();
Syntax\SyntaxFactoryTests.cs (7)
427literal.GetDiagnostics().Verify(); 441literal.GetDiagnostics().Verify(); 455expression.Token.GetDiagnostics().Verify(); 469expression.Token.GetDiagnostics().Verify(); 478token.GetDiagnostics().Verify(); 627parsedWith8.GetDiagnostics().Verify(); 630parsedWithPreview.GetDiagnostics().Verify();
Syntax\SyntaxNodeTests.cs (1)
361compilationUnit.GetDiagnostics().Verify(
Microsoft.CodeAnalysis.CSharp.Test.Utilities (3)
CSharpTestBase.cs (3)
1375comp2.GetEmitDiagnostics().Where(d => shouldCompare(d)).Verify( 2125actualDiagnostics.Verify(expectedDiagnostics); 2136actualDiagnostics.Verify(expectedDiagnostics);
Microsoft.CodeAnalysis.EditorFeatures.UnitTests (1)
Diagnostics\SuppressMessageAttributeWorkspaceTests.cs (1)
70actualDiagnostics.Verify(expectedDiagnostics);
Microsoft.CodeAnalysis.Test.Utilities (1)
Diagnostics\DiagnosticExtensions.cs (1)
63Verify((IEnumerable<Diagnostic>)actual, expected);
Microsoft.CodeAnalysis.VisualBasic.Features.UnitTests (3)
EditAndContinue\Helpers\EditingTestBase.vb (3)
214tree1.GetDiagnostics().Verify() 215tree2.GetDiagnostics().Verify() 268tree.GetDiagnostics().Verify()
Microsoft.CodeAnalysis.VisualBasic.Test.Utilities (1)
ParserTestUtilities.vb (1)
93tree.GetDiagnostics().Verify(expectedDiagnostics)
Microsoft.CodeAnalysis.Workspaces.MSBuild.UnitTests (2)
VisualStudioMSBuildWorkspaceTests.cs (2)
2413comp.GetDiagnostics().Where(d => d.Severity > DiagnosticSeverity.Info).Verify(); 2430comp.GetDiagnostics().Where(d => d.Severity > DiagnosticSeverity.Info).Verify();
Roslyn.Test.PdbUtilities (2)
EditAndContinue\EditAndContinueTest.cs (1)
102diff.EmitResult.Diagnostics.Where(d => d.Severity == DiagnosticSeverity.Error).Verify(expectedErrors);
Reader\PdbValidation.cs (1)
536result.Diagnostics.Where(d => d.Severity == DiagnosticSeverity.Error).Verify();