private static void AssertSeverity(PvsStudioExpectedErrorCode expectedErrorCode, XElement issueType, bool treatPriority1IssuesAsErrors)
 {
     var expectedSeverity = treatPriority1IssuesAsErrors && expectedErrorCode.Priority == 1 ? "ERROR" : "WARNING";
     Assert.Equal(expectedSeverity, issueType.Attribute("Severity").Value);
 }
        private static void AssertResharperIssueTypes(IEnumerable<XElement> issueTypeElements, PvsStudioExpectedErrorCode expectedErrorCode, bool treatPriority1IssuesAsErrors)
        {
            var issueType = Assert.Single(issueTypeElements, _ => _.Attribute("Id").Value == expectedErrorCode.ErrorCode);
            Assert.NotNull(issueType);

            Assert.Equal($"PVS-Studio {expectedErrorCode.Category}. Priority: {expectedErrorCode.Priority}", issueType.Attribute("Category").Value);
            Assert.Equal($"{issueType.Attribute("Id").Value}. {issueType.Attribute("Description").Value}", issueType.Attribute("SubCategory").Value);

            AssertSeverity(expectedErrorCode, issueType, treatPriority1IssuesAsErrors);
        }