9/28/ Automated Source Code Quality Checking Adriaan de Groot Desktop Developers Conference, Ottawa 2006 K Desktop Environment
Adriaan de Groot KDE Quality Team ● 6 years as a KDE contributor ● APIDOX Advocate ● University researcher Who is this guy? ● Someone who jumps off a dock with his glasses on
What is code quality? ● Defect density ● Readability? Maintainability? Documentation quality, style guides... ● Correctness? Functionality? Specifications, user documentation Source Code Quality
What do we want to measure? ● Defect density in... ● Code ● Code documentation ● User documentation ● Functionality and correctness... ● Human Interface Guidelines ● Code guidelines ● Test suites Pragmatic Code Quality
Design goals for a measuring system ● Get the numbers ● Display the numbers with... ● Defect overview ● Visual feedback on fixes ● Navigation and selection ● Defect details and suggestions ● Motivate developers Code Quality System
Architecture Code Quality System SVN Checkout APIDOX Krazy Sanitizer Logfile Log Counter DB View
Uptake within KDE ● Implemented as EnglishBreakfastNetwork.org (EBN) ● APIDOX ● User documentation ● UI testing ● Code style ● Popular with a subset of developers ● Code oriented defect reports lead to fixes Code Quality System
Code Style Checker (Krazy) Code Quality System
Code Style Checker (Krazy) ● Copyright & License ● Performance ● C-isms ● Typos & Cleanliness Code Quality System
Future work ● Extend “naive” code style checkers ● Screen-scrape Coverity ● Apply real code analysis ● Quantify more of the HIG ● Suggest fixes for APIDOX ● Compile farm and testing Code Quality System