microsoft / vscode-java-test
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 140 units with 2,182 lines of code in units (78.9% of code).
    • 0 very complex units (0 lines of code)
    • 1 complex units (90 lines of code)
    • 8 medium complex units (473 lines of code)
    • 20 simple units (527 lines of code)
    • 111 very simple units (1,092 lines of code)
0% | 4% | 21% | 24% | 50%
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
ts0% | 4% | 22% | 24% | 49%
js0% | 0% | 0% | 0% | 100%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
src/runners/junitRunner0% | 34% | 28% | 14% | 21%
src/controller0% | 0% | 33% | 25% | 41%
src/commands/navigation0% | 0% | 64% | 0% | 35%
src/utils0% | 0% | 27% | 39% | 32%
src/runners/testngRunner0% | 0% | 39% | 0% | 60%
src/commands0% | 0% | 7% | 24% | 68%
src/runners/baseRunner0% | 0% | 0% | 65% | 34%
src0% | 0% | 0% | 27% | 72%
src/runners0% | 0% | 0% | 71% | 28%
src/provider0% | 0% | 0% | 0% | 100%
scripts0% | 0% | 0% | 0% | 100%
ROOT0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
public processData()
in src/runners/junitRunner/JUnitRunnerResultAnalyzer.ts
90 34 1
57 18 3
export async function navigateToTestOrTarget()
in src/commands/navigation/navigationCommands.ts
58 17 1
private enlistToTestMapping()
in src/runners/junitRunner/JUnitRunnerResultAnalyzer.ts
75 15 1
async function startWatchingWorkspace()
in src/controller/testController.ts
57 14 0
export const runTests:()
in src/controller/testController.ts
99 14 2
public processData()
in src/runners/testngRunner/TestNGRunnerResultAnalyzer.ts
49 13 1
export async function runTestsFromJavaProjectExplorer()
in src/commands/projectExplorerCommands.ts
36 11 2
function mergeTestMethods()
in src/controller/testController.ts
42 11 1
async function setupUnmanagedFolder()
in src/commands/testDependenciesCommands.ts
40 10 2
37 10 2
public async run()
in src/runners/baseRunner/BaseRunner.ts
60 10 3
export async function getProjectType()
in src/controller/utils.ts
25 9 1
protected processStackTrace()
in src/runners/baseRunner/RunnerResultAnalyzer.ts
21 9 5
18 8 0
async function doActivate()
in src/extension.ts
40 8 2
export function setTestState()
in src/runners/utils.ts
20 8 5
export async function loadRunConfig()
in src/utils/configUtils.ts
31 8 1
export async function openStackTrace()
in src/commands/testReportCommands.ts
25 7 2
export const loadChildren:()
in src/controller/testController.ts
22 7 2