TY - JOUR
T1 - An in-depth investigation into the relationships between structural metrics and unit testability in object-oriented systems
AU - Zhou, Yu Ming
AU - Leung, Hareton
AU - Song, Qin Bao
AU - Zhao, Jian Jun
AU - Lu, Hong Min
AU - Chen, Lin
AU - Xu, Bao Wen
N1 - Funding Information:
Progress of Projects Supported by NSFC
Funding Information:
This work was partially supported by National Natural Science Foundation of China (Grant Nos. 90818027, 91018005, 61272082, 61073029, 61170071, 61003020) and Hong Kong Competitive Earmarked Research Grant (Grant No. PolyU5225/08E).
PY - 2012/12
Y1 - 2012/12
N2 - There is a common belief that structural properties of classes are important factors to determine their unit testability. However, few empirical studies have been conducted to examine the actual impact of structural properties of classes. In this paper, we employ multiple linear regression (MLR) and partial least square regression (PLSR) to investigate the relationships between the metrics measuring structural properties and unit testability of a class. The investigated structural metrics cover five property dimensions, including size, cohesion, coupling, inheritance, and complexity. Our results from open-source software systems show that: (1) most structural metrics are statistically related to unit testability in an expected direction, among which size, complexity, and coupling metrics are the most important predictors; that (2) multivariate regression models based on structural metrics cannot accurately predict unit testability of classes, although they are better able to rank unit testability of classes; that (3) the transition from MLR to PLSR could significantly improve the ability to rank unit testability of classes but cannot improve the ability to predict the unit testing effort of classes.
AB - There is a common belief that structural properties of classes are important factors to determine their unit testability. However, few empirical studies have been conducted to examine the actual impact of structural properties of classes. In this paper, we employ multiple linear regression (MLR) and partial least square regression (PLSR) to investigate the relationships between the metrics measuring structural properties and unit testability of a class. The investigated structural metrics cover five property dimensions, including size, cohesion, coupling, inheritance, and complexity. Our results from open-source software systems show that: (1) most structural metrics are statistically related to unit testability in an expected direction, among which size, complexity, and coupling metrics are the most important predictors; that (2) multivariate regression models based on structural metrics cannot accurately predict unit testability of classes, although they are better able to rank unit testability of classes; that (3) the transition from MLR to PLSR could significantly improve the ability to rank unit testability of classes but cannot improve the ability to predict the unit testing effort of classes.
UR - http://www.scopus.com/inward/record.url?scp=84871782267&partnerID=8YFLogxK
UR - http://www.scopus.com/inward/citedby.url?scp=84871782267&partnerID=8YFLogxK
U2 - 10.1007/s11432-012-4745-x
DO - 10.1007/s11432-012-4745-x
M3 - Article
AN - SCOPUS:84871782267
SN - 1009-2757
VL - 55
SP - 2800
EP - 2815
JO - Science in China, Series F: Information Sciences
JF - Science in China, Series F: Information Sciences
IS - 12
ER -