microsoft / testfx
Conditional Complexity

The distribution of complexity of units (measured with McCabe index).

Intro
  • Conditional complexity (also called cyclomatic complexity) is a term used to measure the complexity of software. The term refers to the number of possible paths through a program function. A higher value ofter means higher maintenance and testing costs (infosecinstitute.com).
  • Conditional complexity is calculated by counting all conditions in the program that can affect the execution path (e.g. if statement, loops, switches, and/or operators, try and catch blocks...).
  • Conditional complexity is measured at the unit level (methods, functions...).
  • Units are classified in four categories based on the measured McCabe index: 1-5 (simple units), 6-10 (medium complex units), 11-25 (complex units), 26+ (very complex units).
Learn more...
Conditional Complexity Overall
  • There are 1,133 units with 14,558 lines of code in units (35.9% of code).
    • 0 very complex units (0 lines of code)
    • 0 complex units (0 lines of code)
    • 29 medium complex units (2,055 lines of code)
    • 80 simple units (3,003 lines of code)
    • 1,024 very simple units (9,500 lines of code)
0% | 0% | 14% | 20% | 65%
Legend:
51+
26-50
11-25
6-10
1-5
Alternative Visuals
Conditional Complexity per Extension
51+
26-50
11-25
6-10
1-5
cs0% | 0% | 14% | 20% | 65%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
src/Adapter0% | 0% | 14% | 22% | 62%
src/TestFramework0% | 0% | 10% | 14% | 74%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
internal static int FindMostSpecific()
in src/TestFramework/Extension.Desktop/RuntimeTypeHelper.cs
83 25 8
private static MSTestSettings ToSettings()
in src/Adapter/MSTest.CoreAdapter/MSTestSettings.cs
114 23 1
private void ExecuteTestsInSource()
in src/Adapter/MSTest.CoreAdapter/Execution/TestExecutionManager.cs
107 21 5
internal TestCase ToTestCase()
in src/Adapter/MSTest.CoreAdapter/ObjectModel/UnitTestElement.cs
97 21 0
internal static MethodBase SelectMethod()
in src/TestFramework/Extension.Desktop/RuntimeTypeHelper.cs
98 20 4
private Assembly OnResolveInternal()
in src/Adapter/PlatformServices.Desktop.Legacy/AssemblyResolver.cs
110 19 3
private Assembly OnResolveInternal()
in src/Adapter/PlatformServices.Desktop/AssemblyResolver.cs
110 19 3
private TestResult ExecuteInternal()
in src/Adapter/MSTest.CoreAdapter/Execution/TestMethodInfo.cs
74 17 1
protected IEnumerable Deploy()
in src/Adapter/PlatformServices.Shared/netstandard1.3/Utilities/ns13DeploymentUtilityBase.cs
96 15 4
internal static int FindMostSpecificType()
in src/TestFramework/Extension.Desktop/RuntimeTypeHelper.cs
63 15 3
protected IEnumerable GetSatellites()
in src/Adapter/PlatformServices.Desktop.Legacy/Utilities/DesktopDeploymentUtility.cs
75 14 3
protected IEnumerable GetSatellites()
in src/Adapter/PlatformServices.Desktop/Utilities/DesktopDeploymentUtility.cs
75 14 3
public void RunClassInitialize()
in src/Adapter/MSTest.CoreAdapter/Execution/TestClassInfo.cs
75 13 1
internal static UnitTestElement ToUnitTestElement()
in src/Adapter/MSTest.CoreAdapter/Extensions/TestCaseExtensions.cs
66 13 2
internal void SendTestCases()
in src/Adapter/MSTest.CoreAdapter/Discovery/UnitTestDiscoverer.cs
64 12 5
public string RunClassCleanup()
in src/Adapter/MSTest.CoreAdapter/Execution/TestClassInfo.cs
65 12 1
public override List GetDataTablesAndViews()
in src/Adapter/PlatformServices.Desktop.Legacy/Data/TestDataConnectionSql.cs
74 12 0
public override List GetDataTablesAndViews()
in src/Adapter/PlatformServices.Desktop/Data/TestDataConnectionSql.cs
74 12 0
internal ICollection GetTests()
in src/Adapter/MSTest.CoreAdapter/Discovery/AssemblyEnumeratorWrapper.cs
55 11 3
internal virtual bool IsValidTestMethod()
in src/Adapter/MSTest.CoreAdapter/Discovery/TestMethodValidator.cs
26 11 3