56 references to Diagnostic
Microsoft.ML.CodeAnalyzer.Tests (56)
Code\ContractsCheckTest.cs (27)
30VerifyCS.Diagnostic(ContractsCheckAnalyzer.NameofDiagnostic.Rule).WithLocation(basis + 8, 46).WithArguments("CheckParam", "paramName", "\"p\""),
31VerifyCS.Diagnostic(ContractsCheckAnalyzer.NameofDiagnostic.Rule).WithLocation(basis + 9, 46).WithArguments("CheckParam", "paramName", "nameof(p) + nameof(p)"),
32VerifyCS.Diagnostic(ContractsCheckAnalyzer.NameofDiagnostic.Rule).WithLocation(basis + 11, 28).WithArguments("CheckValue", "paramName", "\"p\""),
33VerifyCS.Diagnostic(ContractsCheckAnalyzer.NameofDiagnostic.Rule).WithLocation(basis + 13, 39).WithArguments("CheckUserArg", "name", "\"foo\""),
34VerifyCS.Diagnostic(ContractsCheckAnalyzer.ExceptionDiagnostic.Rule).WithLocation(basis + 15, 13).WithArguments("Except"),
35VerifyCS.Diagnostic(ContractsCheckAnalyzer.ExceptionDiagnostic.Rule).WithLocation(basis + 16, 13).WithArguments("ExceptParam"),
36VerifyCS.Diagnostic(ContractsCheckAnalyzer.NameofDiagnostic.Rule).WithLocation(basis + 22, 39).WithArguments("ExceptParam", "paramName", "\"env\""),
37VerifyCS.Diagnostic(ContractsCheckAnalyzer.SimpleMessageDiagnostic.Rule).WithLocation(basis + 24, 29).WithArguments("Check", "$\"Hello {foo} is cool\""),
38VerifyCS.Diagnostic(ContractsCheckAnalyzer.SimpleMessageDiagnostic.Rule).WithLocation(basis + 28, 29).WithArguments("Check", "string.Format(\"Hello {0} is cool\", foo)"),
39VerifyCS.Diagnostic(ContractsCheckAnalyzer.SimpleMessageDiagnostic.Rule).WithLocation(basis + 32, 35).WithArguments("Check", "\"Less fine: \" + env.GetType().Name"),
40VerifyCS.Diagnostic(ContractsCheckAnalyzer.NameofDiagnostic.Rule).WithLocation(basis + 34, 17).WithArguments("CheckUserArg", "name", "\"p\""),
41VerifyCS.Diagnostic(ContractsCheckAnalyzer.DecodeMessageWithLoadContextDiagnostic.Rule).WithLocation(basis + 39, 41).WithArguments("CheckDecode", "\"This message is suspicious\""),
116VerifyCS.Diagnostic(ContractsCheckAnalyzer.ExceptionDiagnostic.Rule).WithLocation(9, 43).WithArguments("ExceptParam"),
117VerifyCS.Diagnostic(ContractsCheckAnalyzer.NameofDiagnostic.Rule).WithLocation(9, 65).WithArguments("ExceptParam", "paramName", "\"yuck\""),
118VerifyCS.Diagnostic(ContractsCheckAnalyzer.NameofDiagnostic.Rule).WithLocation(13, 39).WithArguments("CheckValue", "paramName", "\"str\""),
119VerifyCS.Diagnostic(ContractsCheckAnalyzer.NameofDiagnostic.Rule).WithLocation(14, 66).WithArguments("CheckUserArg", "name", "\"Foo\""),
120VerifyCS.Diagnostic(ContractsCheckAnalyzer.NameofDiagnostic.Rule).WithLocation(15, 57).WithArguments("CheckUserArg", "name", "\"Bar\""),
121VerifyCS.Diagnostic(ContractsCheckAnalyzer.NameofDiagnostic.Rule).WithLocation(16, 57).WithArguments("CheckUserArg", "name", "\"A\""),
122VerifyCS.Diagnostic(ContractsCheckAnalyzer.NameofDiagnostic.Rule).WithLocation(17, 52).WithArguments("ExceptParam", "paramName", "\"Bar\""),
123VerifyCS.Diagnostic(ContractsCheckAnalyzer.NameofDiagnostic.Rule).WithLocation(20, 17).WithArguments("CheckParam", "paramName", "\"isFive\""),
124VerifyCS.Diagnostic(ContractsCheckAnalyzer.NameofDiagnostic.Rule).WithLocation(21, 49).WithArguments("CheckValue", "paramName", "\"Y\""),
125VerifyCS.Diagnostic(ContractsCheckAnalyzer.NameofDiagnostic.Rule).WithLocation(22, 52).WithArguments("ExceptParam", "paramName", "\"tom\""),
126VerifyCS.Diagnostic(ContractsCheckAnalyzer.NameofDiagnostic.Rule).WithLocation(23, 39).WithArguments("CheckValue", "paramName", "\"noMatch\""),
127VerifyCS.Diagnostic(ContractsCheckAnalyzer.NameofDiagnostic.Rule).WithLocation(24, 53).WithArguments("CheckUserArg", "name", "\"chumble\""),
128VerifyCS.Diagnostic(ContractsCheckAnalyzer.NameofDiagnostic.Rule).WithLocation(25, 53).WithArguments("CheckUserArg", "name", "\"sp\""),
147VerifyCS.Diagnostic(ContractsCheckAnalyzer.ExceptionDiagnostic.Rule).WithLocation(9, 43).WithArguments("ExceptParam"),
148VerifyCS.Diagnostic(ContractsCheckAnalyzer.NameofDiagnostic.Rule).WithLocation(23, 39).WithArguments("CheckValue", "paramName", "\"noMatch\""),
Code\NameTest.cs (29)
21VerifyCS.Diagnostic(NameAnalyzer.PrivateFieldName.Rule).WithLocation(6, 21).WithArguments("foo"),
22VerifyCS.Diagnostic(NameAnalyzer.PrivateFieldName.Rule).WithLocation(8, 24).WithArguments("_Bubba"),
23VerifyCS.Diagnostic(NameAnalyzer.PrivateFieldName.Rule).WithLocation(9, 22).WithArguments("_shouldParseHTML"),
24VerifyCS.Diagnostic(NameAnalyzer.PrivateFieldName.Rule).WithLocation(12, 23).WithArguments("BillyClub"),
25VerifyCS.Diagnostic(NameAnalyzer.PrivateFieldName.Rule).WithLocation(14, 30).WithArguments("bob"),
26VerifyCS.Diagnostic(NameAnalyzer.PrivateFieldName.Rule).WithLocation(15, 30).WithArguments("CHAZ"),
27VerifyCS.Diagnostic(NameAnalyzer.PrivateFieldName.Rule).WithLocation(18, 21).WithArguments("_liveFromNYC"),
28VerifyCS.Diagnostic(NameAnalyzer.PrivateFieldName.Rule).WithLocation(20, 28).WithArguments("nice"),
61VerifyCS.Diagnostic(NameAnalyzer.GeneralName.Rule).WithLocation(7, 11).WithArguments("CLASS"),
62VerifyCS.Diagnostic(NameAnalyzer.GeneralName.Rule).WithLocation(9, 20).WithArguments("alice"),
63VerifyCS.Diagnostic(NameAnalyzer.GeneralName.Rule).WithLocation(10, 21).WithArguments("_bob"),
64VerifyCS.Diagnostic(NameAnalyzer.GeneralName.Rule).WithLocation(11, 22).WithArguments("_chaz"),
65VerifyCS.Diagnostic(NameAnalyzer.GeneralName.Rule).WithLocation(12, 30).WithArguments("emily"),
66VerifyCS.Diagnostic(NameAnalyzer.GeneralName.Rule).WithLocation(12, 37).WithArguments("_francis"),
67VerifyCS.Diagnostic(NameAnalyzer.GeneralName.Rule).WithLocation(17, 21).WithArguments("this_is_not_python"),
68VerifyCS.Diagnostic(NameAnalyzer.GeneralName.Rule).WithLocation(18, 21).WithArguments("thisIsNotJava"),
69VerifyCS.Diagnostic(NameAnalyzer.PrivateFieldName.Rule).WithLocation(22, 30).WithArguments("BadEvent"),
70VerifyCS.Diagnostic(NameAnalyzer.GeneralName.Rule).WithLocation(23, 29).WithArguments("bad_event"),
71VerifyCS.Diagnostic(NameAnalyzer.GeneralName.Rule).WithLocation(26, 30).WithArguments("_badEv"),
72VerifyCS.Diagnostic(NameAnalyzer.GeneralName.Rule).WithLocation(28, 29).WithArguments("one"),
73VerifyCS.Diagnostic(NameAnalyzer.GeneralName.Rule).WithLocation(28, 39).WithArguments("three"),
74VerifyCS.Diagnostic(NameAnalyzer.GeneralName.Rule).WithLocation(29, 22).WithArguments("enumb"),
75VerifyCS.Diagnostic(NameAnalyzer.GeneralName.Rule).WithLocation(29, 35).WithArguments("Two_Two"),
76VerifyCS.Diagnostic(NameAnalyzer.GeneralName.Rule).WithLocation(29, 44).WithArguments("_three"),
77VerifyCS.Diagnostic(NameAnalyzer.GeneralName.Rule).WithLocation(31, 25).WithArguments("_m2"),
78VerifyCS.Diagnostic(NameAnalyzer.GeneralName.Rule).WithLocation(38, 12).WithArguments("marco"),
79VerifyCS.Diagnostic(NameAnalyzer.GeneralName.Rule).WithLocation(38, 31).WithArguments("polo"),
153VerifyCS.Diagnostic(NameAnalyzer.GeneralName.Rule).WithLocation(7, 11).WithArguments("CLASS"),
154VerifyCS.Diagnostic(NameAnalyzer.GeneralName.Rule).WithLocation(13, 21).WithArguments("masterBlaster"),