72 references to Diagnostic
Microsoft.CodeAnalysis.NetAnalyzers.UnitTests (48)
Microsoft.NetCore.Analyzers\Security\DataSetDataTableInIFormatterObjectGraphTests.cs (1)
261=> VerifyCS.Diagnostic(DataSetDataTableInIFormatterSerializableObjectGraphAnalyzer.ObjectGraphContainsDangerousTypeDescriptor)
Microsoft.NetCore.Analyzers\Security\DataSetDataTableInObjectGraphTests.cs (1)
421=> VerifyCS.Diagnostic(DataSetDataTableInSerializableObjectGraphAnalyzer.ObjectGraphContainsDangerousTypeDescriptor)
Microsoft.NetCore.Analyzers\Security\DataSetDataTableInSerializableTypeTests.cs (3)
513=> VerifyCS.Diagnostic(DataSetDataTableInSerializableTypeAnalyzer.SerializableContainsDangerousType) 520=> VerifyCS.Diagnostic(DataSetDataTableInSerializableTypeAnalyzer.RceSerializableContainsDangerousType) 527=> VerifyCS.Diagnostic(DataSetDataTableInSerializableTypeAnalyzer.RceAutogeneratedSerializableContainsDangerousType)
Microsoft.NetCore.Analyzers\Security\DataSetDataTableInWebSerializableObjectGraphTests.cs (1)
136=> VerifyCS.Diagnostic(DataSetDataTableInWebSerializableObjectGraphAnalyzer.ObjectGraphContainsDangerousTypeDescriptor)
Microsoft.NetCore.Analyzers\Security\DoNotDisableHttpClientCRLCheckTests.cs (1)
341=> VerifyCS.Diagnostic(rule)
Microsoft.NetCore.Analyzers\Security\DoNotDisableSchUseStrongCryptoTests.cs (1)
280=> VerifyCS.Diagnostic(DoNotSetSwitch.DoNotDisableSchUseStrongCryptoRule)
Microsoft.NetCore.Analyzers\Security\DoNotDisableUsingServicePointManagerSecurityProtocolsTests.cs (1)
281=> VerifyCS.Diagnostic(DoNotSetSwitch.DoNotDisableSpmSecurityProtocolsRule)
Microsoft.NetCore.Analyzers\Security\DoNotInstallRootCertTests.cs (1)
461=> VerifyCS.Diagnostic(rule)
Microsoft.NetCore.Analyzers\Security\DoNotUseCreateEncryptorWithNonDefaultIVTests.cs (1)
177=> VerifyCS.Diagnostic(rule)
Microsoft.NetCore.Analyzers\Security\DoNotUseDataSetReadXmlTests.cs (2)
212=> VerifyCS.Diagnostic(DoNotUseDataSetReadXml.RealMethodUsedDescriptor) 219=> VerifyCS.Diagnostic(DoNotUseDataSetReadXml.RealMethodUsedInAutogeneratedDescriptor)
Microsoft.NetCore.Analyzers\Security\DoNotUseDataTableReadXmlTests.cs (1)
82=> VerifyCS.Diagnostic(DoNotUseDataTableReadXml.RealMethodUsedDescriptor)
Microsoft.NetCore.Analyzers\Security\DoNotUseDeprecatedSecurityProtocolsTests.cs (3)
436VerifyCS.Diagnostic(DoNotUseDeprecatedSecurityProtocols.DeprecatedRule).WithSpan(9, 48, 9, 102).WithArguments("3264"), 437VerifyCS.Diagnostic(DoNotUseDeprecatedSecurityProtocols.HardCodedRule).WithSpan(9, 48, 9, 74).WithArguments("Tls12")); 530=> VerifyCS.Diagnostic(rule)
Microsoft.NetCore.Analyzers\Security\DoNotUseInsecureCryptographicAlgorithmsTests.cs (1)
3273=> VerifyCS.Diagnostic(rule)
Microsoft.NetCore.Analyzers\Security\DoNotUseInsecureDeserializerBinaryFormatterMethodsTests.cs (1)
214=> VerifyCS.Diagnostic(DoNotUseInsecureDeserializerBinaryFormatterMethods.RealMethodUsedDescriptor)
Microsoft.NetCore.Analyzers\Security\DoNotUseInsecureDeserializerBinaryFormatterWithoutBinderTests.cs (1)
1502=> VerifyCS.Diagnostic(rule)
Microsoft.NetCore.Analyzers\Security\DoNotUseInsecureDeserializerJavascriptSerializerWithSimpleTypeResolverTests.cs (1)
664=> VerifyCS.Diagnostic(rule)
Microsoft.NetCore.Analyzers\Security\DoNotUseInsecureDeserializerJsonNetWithoutBinderTests.cs (1)
822=> VerifyCS.Diagnostic(rule)
Microsoft.NetCore.Analyzers\Security\DoNotUseInsecureDeserializerNetDataContractSerializerWithoutBinderTests.cs (1)
1073=> VerifyCS.Diagnostic(rule)
Microsoft.NetCore.Analyzers\Security\DoNotUseInsecureSettingsForJsonNetTests.cs (1)
1433=> VerifyCS.Diagnostic(rule)
Microsoft.NetCore.Analyzers\Security\DoNotUseWeakKDFInsufficientIterationCountTests.cs (1)
453=> VerifyCS.Diagnostic(rule)
Microsoft.NetCore.Analyzers\Security\JsonNetTypeNameHandlingTests.cs (1)
264=> VerifyCS.Diagnostic(rule)
Microsoft.NetCore.Analyzers\Security\SslProtocolsAnalyzerTests.cs (3)
495VerifyCS.Diagnostic(SslProtocolsAnalyzer.HardcodedRule).WithSpan(9, 34, 9, 52).WithArguments("Tls12"), 496VerifyCS.Diagnostic(SslProtocolsAnalyzer.DeprecatedRule).WithSpan(9, 34, 9, 72).WithArguments("3264")); 554=> VerifyCS.Diagnostic(rule)
Microsoft.NetCore.Analyzers\Security\UseAutoValidateAntiforgeryTokenTests.cs (1)
18=> VerifyCS.Diagnostic(rule)
Microsoft.NetCore.Analyzers\Security\UseDefaultDllImportSearchPathsAttributeForLibraryImportAndDllImportTests.cs (1)
779=> VerifyCS.Diagnostic(rule)
Microsoft.NetCore.Analyzers\Security\UseDefaultDllImportSearchPathsAttributeTests.cs (1)
650=> VerifyCS.Diagnostic(rule)
Microsoft.NetCore.Analyzers\Security\UseSecureCookiesASPNetCoreTests.cs (1)
336=> VerifyCS.Diagnostic(rule)
Microsoft.NetFramework.Analyzers\DoNotUseInsecureDtdProcessingDoNotUseLoadXmlTests.cs (1)
19=> VerifyCS.Diagnostic(DoNotUseInsecureDtdProcessingAnalyzer.RuleDoNotUseDtdProcessingOverloads).WithLocation(line, column).WithArguments("LoadXml");
Microsoft.NetFramework.Analyzers\DoNotUseInsecureDtdProcessingDoNotUseSetInnerXmlTests.cs (1)
888=> VerifyCS.Diagnostic(DoNotUseInsecureDtdProcessingAnalyzer.RuleDoNotUseSetInnerXml).WithLocation(line, column);
Microsoft.NetFramework.Analyzers\DoNotUseInsecureDtdProcessingReviewDataViewCollectionStringTests.cs (1)
19=> VerifyCS.Diagnostic(DoNotUseInsecureDtdProcessingAnalyzer.RuleReviewDtdProcessingProperties).WithLocation(line, column);
Microsoft.NetFramework.Analyzers\DoNotUseInsecureDtdProcessingUseXmlReaderForDataSetReadXmlSchemaTests.cs (1)
19=> VerifyCS.Diagnostic(DoNotUseInsecureDtdProcessingAnalyzer.RuleDoNotUseDtdProcessingOverloads).WithLocation(line, column).WithArguments("ReadXmlSchema");
Microsoft.NetFramework.Analyzers\DoNotUseInsecureDtdProcessingUseXmlReaderForDataSetReadXmlTests.cs (1)
19=> VerifyCS.Diagnostic(DoNotUseInsecureDtdProcessingAnalyzer.RuleDoNotUseDtdProcessingOverloads).WithLocation(line, column).WithArguments("ReadXml");
Microsoft.NetFramework.Analyzers\DoNotUseInsecureDtdProcessingUseXmlReaderForDataTableReadXmlSchemaTests.cs (1)
19=> VerifyCS.Diagnostic(DoNotUseInsecureDtdProcessingAnalyzer.RuleDoNotUseDtdProcessingOverloads).WithLocation(line, column).WithArguments("ReadXmlSchema");
Microsoft.NetFramework.Analyzers\DoNotUseInsecureDtdProcessingUseXmlReaderForDataTableReadXmlTests.cs (1)
19=> VerifyCS.Diagnostic(DoNotUseInsecureDtdProcessingAnalyzer.RuleDoNotUseDtdProcessingOverloads).WithLocation(line, column).WithArguments("ReadXml");
Microsoft.NetFramework.Analyzers\DoNotUseInsecureDtdProcessingUseXmlReaderForDeserializeTests.cs (1)
19=> VerifyCS.Diagnostic(DoNotUseInsecureDtdProcessingAnalyzer.RuleDoNotUseDtdProcessingOverloads).WithLocation(line, column).WithArguments("Deserialize");
Microsoft.NetFramework.Analyzers\DoNotUseInsecureDtdProcessingUseXmlReaderForLoadTests.cs (1)
19=> VerifyCS.Diagnostic(DoNotUseInsecureDtdProcessingAnalyzer.RuleDoNotUseDtdProcessingOverloads).WithLocation(line, column).WithArguments("Load");
Microsoft.NetFramework.Analyzers\DoNotUseInsecureDtdProcessingUseXmlReaderForSchemaReadTests.cs (1)
19=> VerifyCS.Diagnostic(DoNotUseInsecureDtdProcessingAnalyzer.RuleDoNotUseDtdProcessingOverloads).WithLocation(line, column).WithArguments("Read");
Microsoft.NetFramework.Analyzers\DoNotUseInsecureDtdProcessingUseXmlReaderForXPathDocumentTests.cs (1)
19=> VerifyCS.Diagnostic(DoNotUseInsecureDtdProcessingAnalyzer.RuleDoNotUseDtdProcessingOverloads).WithLocation(line, column).WithArguments(".ctor");
Microsoft.NetFramework.Analyzers\DoNotUseInsecureDtdProcessingXmlDocumentConstructedWithNoSecureResolverTests.cs (1)
19=> VerifyCS.Diagnostic(DoNotUseInsecureDtdProcessingAnalyzer.RuleXmlDocumentWithNoSecureResolver).WithLocation(line, column);
Microsoft.NetFramework.Analyzers\DoNotUseInsecureDtdProcessingXmlDocumentSecureDefaultXmlResolverAnalyzerTests.cs (1)
16=> VerifyCS.Diagnostic(DoNotUseInsecureDtdProcessingAnalyzer.RuleXmlDocumentWithNoSecureResolver).WithLocation(line, column);
Microsoft.NetFramework.Analyzers\DoNotUseInsecureDtdProcessingXmlTextReaderConstructedWithNoSecureResolutionTests.cs (1)
20=> VerifyCS.Diagnostic(DoNotUseInsecureDtdProcessingAnalyzer.RuleXmlTextReaderConstructedWithNoSecureResolution).WithLocation(line, column);
Microsoft.NetFramework.Analyzers\DoNotUseInsecureDtdProcessingXmlTextReaderSetInsecureResolutionTests.cs (1)
19=> VerifyCS.Diagnostic(DoNotUseInsecureDtdProcessingAnalyzer.RuleXmlTextReaderSetInsecureResolution).WithLocation(line, column);
Roslyn.Diagnostics.Analyzers.UnitTests (24)
DoNotCopyValueTests.cs (24)
156VerifyCS.Diagnostic(AbstractDoNotCopyValue.NoAssignValueFromReferenceRule).WithLocation(0).WithArguments("System.Runtime.InteropServices.GCHandle")); 267VerifyCS.Diagnostic(AbstractDoNotCopyValue.NoAssignValueFromReferenceRule).WithLocation(0).WithArguments("System.Runtime.InteropServices.GCHandle")); 299VerifyCS.Diagnostic(AbstractDoNotCopyValue.UnsupportedUseRule).WithLocation(0).WithArguments("System.Runtime.InteropServices.GCHandle", "FieldReference"), 301VerifyCS.Diagnostic(AbstractDoNotCopyValue.UnsupportedUseRule).WithLocation(1).WithArguments("System.Runtime.InteropServices.GCHandle", "LocalReference")); 333VerifyCS.Diagnostic(AbstractDoNotCopyValue.UnsupportedUseRule).WithLocation(0).WithArguments("System.Runtime.InteropServices.GCHandle", "FieldReference"), 335VerifyCS.Diagnostic(AbstractDoNotCopyValue.UnsupportedUseRule).WithLocation(1).WithArguments("System.Runtime.InteropServices.GCHandle", "LocalReference")); 387VerifyCS.Diagnostic(AbstractDoNotCopyValue.UnsupportedUseRule).WithLocation(0).WithArguments("System.Runtime.InteropServices.GCHandle", "FieldReference"), 389VerifyCS.Diagnostic(AbstractDoNotCopyValue.UnsupportedUseRule).WithLocation(1).WithArguments("System.Runtime.InteropServices.GCHandle", "LocalReference"), 391VerifyCS.Diagnostic(AbstractDoNotCopyValue.UnsupportedUseRule).WithLocation(2).WithArguments("System.Runtime.InteropServices.GCHandle", "FieldReference"), 393VerifyCS.Diagnostic(AbstractDoNotCopyValue.UnsupportedUseRule).WithLocation(3).WithArguments("System.Runtime.InteropServices.GCHandle", "FieldReference"), 395VerifyCS.Diagnostic(AbstractDoNotCopyValue.UnsupportedUseRule).WithLocation(4).WithArguments("System.Runtime.InteropServices.GCHandle", "LocalReference"), 397VerifyCS.Diagnostic(AbstractDoNotCopyValue.UnsupportedUseRule).WithLocation(5).WithArguments("System.Runtime.InteropServices.GCHandle", "LocalReference"), 399VerifyCS.Diagnostic(AbstractDoNotCopyValue.UnsupportedUseRule).WithLocation(6).WithArguments("System.Runtime.InteropServices.GCHandle", "LocalReference")); 608VerifyCS.Diagnostic(AbstractDoNotCopyValue.UnsupportedUseRule).WithLocation(0).WithArguments("CannotCopy", "FieldReference"), 724("in", "") => [VerifyCS.Diagnostic(AbstractDoNotCopyValue.UnsupportedUseRule).WithLocation(0).WithArguments("CannotCopy", "ParameterReference")], 1097VerifyCS.Diagnostic(AbstractDoNotCopyValue.NoAssignValueFromReferenceRule).WithLocation(0).WithArguments("CannotCopy"), 1099VerifyCS.Diagnostic(AbstractDoNotCopyValue.NoAssignValueFromReferenceRule).WithLocation(1).WithArguments("CannotCopy"), 1132VerifyCS.Diagnostic(AbstractDoNotCopyValue.NoReturnValueFromReferenceRule).WithLocation(0).WithArguments("CannotCopy"), 1166VerifyCS.Diagnostic(AbstractDoNotCopyValue.UnsupportedUseRule).WithLocation(0).WithArguments("CannotCopy", "FieldReference")); 1179VerifyCS.Diagnostic(AbstractDoNotCopyValue.AvoidNullableWrapperRule).WithLocation(0).WithArguments("System.Runtime.InteropServices.GCHandle?", "FieldInitializer")); 1209VerifyCS.Diagnostic(AbstractDoNotCopyValue.NoFieldOfCopyableTypeRule).WithLocation(0).WithArguments("CannotCopy", "C2.field2")); 1261VerifyCS.Diagnostic(AbstractDoNotCopyValue.NoAutoPropertyRule).WithLocation(0).WithArguments("CannotCopy", "C1.Property3"), 1263VerifyCS.Diagnostic(AbstractDoNotCopyValue.NoAutoPropertyRule).WithLocation(1).WithArguments("CannotCopy", "C2.Property3")); 1430VerifyCS.Diagnostic(AbstractDoNotCopyValue.UnsupportedUseRule).WithLocation(0).WithArguments("S", "LocalReference")