22 references to GetWarningLevel
Microsoft.CodeAnalysis.CSharp (2)
Compilation\CSharpDiagnosticFilter.cs (1)
81ErrorFacts.GetWarningLevel(ErrorCode.WRN_ALinkWarn),
Errors\MessageProvider.cs (1)
91return ErrorFacts.GetWarningLevel((ErrorCode)code);
Microsoft.CodeAnalysis.CSharp.Syntax.UnitTests (20)
Diagnostics\DiagnosticTest.cs (20)
220Assert.NotEqual(0, ErrorFacts.GetWarningLevel(errorCode)); 225Assert.Equal(0, ErrorFacts.GetWarningLevel(errorCode)); 236Assert.Equal(2, ErrorFacts.GetWarningLevel(ErrorCode.WRN_DeprecatedCollectionInitAddStr)); 237Assert.Equal(1, ErrorFacts.GetWarningLevel(ErrorCode.WRN_DefaultValueForUnconsumedLocation)); 238Assert.Equal(2, ErrorFacts.GetWarningLevel(ErrorCode.WRN_UnmatchedParamRefTag)); 239Assert.Equal(2, ErrorFacts.GetWarningLevel(ErrorCode.WRN_UnmatchedTypeParamRefTag)); 240Assert.Equal(1, ErrorFacts.GetWarningLevel(ErrorCode.WRN_ReferencedAssemblyReferencesLinkedPIA)); 241Assert.Equal(2, ErrorFacts.GetWarningLevel(ErrorCode.WRN_DynamicDispatchToConditionalMethod)); 242Assert.Equal(3, ErrorFacts.GetWarningLevel(ErrorCode.WRN_IsDynamicIsConfusing)); 243Assert.Equal(2, ErrorFacts.GetWarningLevel(ErrorCode.WRN_NoSources)); 307Assert.Equal(1, ErrorFacts.GetWarningLevel(errorCode)); 312Assert.Equal(2, ErrorFacts.GetWarningLevel(errorCode)); 317Assert.Equal(3, ErrorFacts.GetWarningLevel(errorCode)); 411Assert.Equal(1, ErrorFacts.GetWarningLevel(errorCode)); 414Assert.Equal(4, ErrorFacts.GetWarningLevel(errorCode)); 433Assert.Equal(5, ErrorFacts.GetWarningLevel(errorCode)); 437Assert.Equal(6, ErrorFacts.GetWarningLevel(errorCode)); 441Assert.Equal(7, ErrorFacts.GetWarningLevel(errorCode)); 445Assert.Equal(8, ErrorFacts.GetWarningLevel(errorCode)); 450Assert.True(false, $"Please update this test case with a proper warning level ({ErrorFacts.GetWarningLevel(errorCode)}) for '{errorCodeName}'");