ArchiMetrics.CodeReview.Rules.Tests.Rules.NodeReviewerTests.PerformSolutionInspection C# (CSharp) Method

PerformSolutionInspection() public static method

public static PerformSolutionInspection ( string code, Type evaluatorType ) : Task>
code string
evaluatorType System.Type
return Task>
        public static Task<IEnumerable<EvaluationResult>> PerformSolutionInspection(string code, Type evaluatorType)
        {
            var inspector = new NodeReviewer(new[] { (ICodeEvaluation)Activator.CreateInstance(evaluatorType) }, Enumerable.Empty<ISymbolEvaluation>());
            code = "namespace TestSpace { public class ParseClass { " + code + " } }";

            var solution = CreateSolution(code);
            var task = inspector.Inspect(solution);
            return task;
        }