[go: up one dir, main page]
More Web Proxy on the site http://driver.im/ skip to main content
10.1145/3387904.3389273acmconferencesArticle/Chapter ViewAbstractPublication PagesicseConference Proceedingsconference-collections
research-article

Measuring Software Testability Modulo Test Quality

Published: 12 September 2020 Publication History

Abstract

Comprehending the degree to which software components support testing is important to accurately schedule testing activities, train developers, and plan effective refactoring actions. Software testability estimates such property by relating code characteristics to the test effort. The main studies of testability reported in the literature investigate the relation between class metrics and test effort in terms of the size and complexity of the associated test suites. They report a moderate correlation of some class metrics to test-effort metrics, but suffer from two main limitations: (i) the results hardly generalize due to the small empirical evidence (datasets with no more than eight software projects); and (ii) mostly ignore the quality of the tests. However, considering the quality of the tests is important. Indeed, a class may have a low test effort because the associated tests are of poor quality, and not because the class is easier to test. In this paper, we propose an approach to measure testability that normalizes the test effort with respect to the test quality, which we quantify in terms of code coverage and mutation score. We present the results of a set of experiments on a dataset of 9,861 Java classes, belonging to 1,186 open source projects, with around 1.5 million of lines of code overall. The results confirm that normalizing the test effort with respect to the test quality largely improves the correlation between class metrics and the test effort. Better correlations result in better prediction power and thus better prediction of the test effort.

References

[1]
Nadia Alshahwan, Mark Harman, Alessandro Marchetto, and Paolo Tonella. 2009. Improving Web Application Testing Using Testability Measures. In IEEE International Symposium on Web Systems Evolution (WSE). 49--58.
[2]
Linda Badri, Mourad Badri, and Fadel Toure. 2011. An Empirical Analysis of Lack of Cohesion Metrics for Predicting Testability of Classes. International Journal of Software Engineering and Its Applications 5, 2 (2011), 69--85.
[3]
Mourad Badri and Fadel Toure. 2012. Empirical Analysis of Object-Oriented Design Metrics for Predicting Unit Testing Effort of Classes. Journal of Software Engineering and Applications 5, 7 (2012), 513.
[4]
Mourad Badri and Fadel Toure. 2012. Evaluating the Effect of Control Flow on the Unit Testing Effort of Classes: An Empirical Analysis. Advances in Software Engineering (2012).
[5]
J. Bansiya and C. G. Davis. 2002. A Hierarchical Model for Object-Oriented Design Quality Assessment. IEEE Transactions on Software Engineering 28, 1 (2002), 4--17.
[6]
Victor R. Basili, Lionel C. Briand, and Walcélio L Melo. 1996. A Validation of Object-Oriented Design Metrics as Quality Indicators. IEEE Transactions on Software Engineering 22, 10 (1996), 751--761.
[7]
Benoit Baudry, Yves Le Traon, and Gerson Sunyé. 2002. Testability Analysis of a UML Class Diagram. In IEEE International Software Metrics Symposium (METRICS). 54.
[8]
Benoit Baudry, Yves Le Traon, Gerson Sunyé, and Jean-Marc Jézéquel. 2001. Towards a 'Safe' Use of Design Patterns to Improve OO Software Testability. In International Symposium on Software Reliability Engineering (ISSRE). 324--331.
[9]
Benoit Baudry, Yves Le Traon, Gerson Sunyé, and Jean-Marc Jézéquel. 2003. Measuring and Improving Design Patterns Testability. In IEEE International Software Metrics Symposium (METRICS). 50.
[10]
Robert V. Binder. 1994. Design for Testability in Object-Oriented Systems. Commun. ACM 37, 9 (1994), 87--101.
[11]
Lionel C Briand, Jürgen Wüst, John W Daly, and D Victor Porter. 2000. Exploring the Relationships Between Design Measures and Software Quality in Object-Oriented Systems. Journal of Systems and Software 51, 3 (2000), 245--273.
[12]
Magiel Bruntink and Arie van Deursen. 2004. Predicting Class Testability Using Object-Oriented Metrics. In IEEE International Workshop on Source Code Analysis and Manipulation (SCAM). 136--145.
[13]
Magiel Bruntink and Arie van Deursen. 2006. An Empirical Study Into Class Testability. Journal of Systems and Software 79, 9 (2006), 1219--1232.
[14]
Shyam R. Chidamber and Chris F. Kemerer. 1994. A Metrics Suite for Object Oriented Design. IEEE Transactions on Software Engineering 20, 6 (1994), 476--493.
[15]
Jacob Cohen. 2013. Statistical Power Analysis for the Behavioral Sciences. Routledge.
[16]
Henry Coles. 2020. PIT Mutation Testing. https://pitest.org
[17]
Gregory W. Corder and Dale I. Foreman. 2011. Nonparametric Statistics for Non-Statisticians. John Wiley & Sons, Inc.
[18]
Robinson Crusoé da Cruz and Marcelo Medeiros Eler. 2017. An Empirical Analysis of the Correlation Between CK Metrics, Test Coverage and Mutation Score. In International Conference on Enterprise Information Systems (ICEIS). 341--350.
[19]
Ralph B. D'agostino, Albert Belanger, and Ralph B. D'Agostino Jr. 1990. A Suggestion for Using Powerful and Informative Tests of Normality. The American Statistician 44, 4 (1990), 316--321.
[20]
R. A. DeMillo, R. J. Lipton, and F. G. Sayward. 1978. Hints on Test Data Selection: Help for the Practicing Programmer. Computer 11, 4 (April 1978), 34--41.
[21]
Mark Fewster and Dorothy Graham. 1999. Software Test Automation: Effective Use of Test Execution Tools. ACM Press.
[22]
Vahid Garousi, Michael Felderer, and Feyza Nur Kilicaslan. 2019. A Survey on Software Testability. Information & Software Technology 108 (2019), 35--64.
[23]
P. K. Goyal and G. Joshi. 2014. QMOOD Metric Sets to Assess Quality of Java Program. In International Conference on Issues and Challenges in Intelligent Computing Techniques (ICICT). 520--533.
[24]
Vandana Gupta, K.K. Aggarwal, and Y. Singh. 2005. A Fuzzy Approach for Integrated Measure of Object-Oriented Software Testability. Journal of Computer Science 1, 2 (2005), 276--282.
[25]
Tibor Gyimothy, Rudolf Ferenc, and Istvan Siket. 2005. Empirical Validation of Object-Oriented Metrics on Open Source Software for Fault Prediction. IEEE Transactions on Software Engineering 31, 10 (2005), 897--910.
[26]
Mark Harman, Lin Hu, Rob Hierons, Joachim Wegener, Harmen Sthamer, André Baresel, and Marc Roper. 2004. Testability Transformation. IEEE Transactions on Software Engineering 30, 1 (Jan. 2004), 3--16.
[27]
Jan Hauke and Tomasz Kossowski. 2011. Comparison of Values of Pearson's and Spearman's Correlation Coefficients on the Same Sets of Data. Quaestiones Geographicae 30, 2 (2011), 87--93.
[28]
Brian Henderson-Sellers. 1996. Object-Oriented Metrics: Measures of Complexity. Prentice-Hall, Inc.
[29]
Joseph R. Horgan, Saul London, and Michael R. Lyu. 1994. Achieving Software Quality with Testing Coverage Measures. Computer 27, 9 (Sept. 1994), 60--69.
[30]
Kevin Jalbert and Jeremy S. Bradbury. 2012. Predicting Mutation Score Using Source Code and Test Suite Metrics. In International Workshop on Realizing Artificial Intelligence Synergies in Software Engineering (RAISE). 42--46.
[31]
Marian Jureczko and Diomidis Spinellis. 2010. Using Object-Oriented Design Metrics to Predict Software Defects. Vol. Models and Methodology of System Dependability. Oficyna Wydawnicza Politechniki Wroclawskiej, Wroclaw, Poland, 69--81.
[32]
MH Khan and Reena Srivastava. 2015. Flexibility: A Key Factor To Testability. International Journal of Software Engineering & Applications 6, 1 (2015), 89.
[33]
Taghi M. Khoshgoftaar, Edward B Allen, and Zhiwei Xu. 2000. Predicting Testability of Program Modules Using a Neural Network. In IEEE Symposium on Application-Specific Systems and Software Engineering Technology (ASSET). 57--62.
[34]
Panagiotis Louridas, Antti Pöyhönen, and Julien Rentropoles. 2020. CKJM-extended. http://gromit.iiar.pwr.wroc.pl/p_inf/ckjm
[35]
Dongyu Mao, Lingchao Chen, and Lingming Zhang. 2019. An Extensive Study on Cross-Project Predictive Mutation Testing. In IEEE International Conference on Software Testing, Verification and Validation (ICST). 160--171.
[36]
R. Martin. 1995. OO Design Quality Metrics: An Analysis of Dependencies. ROAD 2, 3 (1995).
[37]
Michael Mattsson. 1999. Effort Distribution in a Six Year Industrial Application Framework Project. In IEEE International Conference on Software Maintenance (ICSM). 326--333.
[38]
T. J. McCabe. 1976. A Complexity Measure. IEEE Transactions on Software Engineering SE-2, 4 (Dec. 1976), 308--320.
[39]
Gerard Meszaros. 2007. xUnit Test Patterns: Refactoring Test Code. Pearson Education.
[40]
Joan C Miller and Clifford J Maloney. 1963. Systematic Mistake Analysis of Digital Computer Programs. Commun. ACM 6, 2 (1963), 58--63.
[41]
Samar Mouchawrab, Lionel C. Briand, and Yvan Labiche. 2005. A Measurement Framework for Object-Oriented Software Testability. Information & Software Technology 47, 15 (2005), 979--997.
[42]
Mountainminds GmbH & Co. KG and Contributors. 2020. JaCoCo: Java Code Coverage Library. https://www.jacoco.org
[43]
Roger Pressman. 2009. Software Engineering: A Practitioner's Approach (seventh ed.). McGraw-Hill, Inc.
[44]
Nornadiah Mohd Razali and Yap Bee Wah. 2011. Power Comparisons of Shapiro-Wilk, Kolmogorov-Smirnov, Lilliefors and Anderson-Darling Tests. Journal of Statistical Modeling and Analytics 2, 1 (2011), 21--33.
[45]
Robert W. Sebesta. 2012. Concepts of Programming Languages. Pearson.
[46]
Yogesh Singh, Arvinder Kaur, and Ruchika Malhotra. 2008. Predicting Testing Effort Using Artificial Neural Network. In World Congress on Engineering and Computer Science (WCECS). 1012--1017.
[47]
Mei-Huei Tang, Ming-Hung Kao, and Mei-Hwa Chen. 1999. An Empirical Study on Object-Oriented Metrics. In International Symposium on Software Metrics (METRICS). 242.
[48]
Valerio Terragni, Pasquale Salza, and Mauro Pezzè. 2020. Measuring Software Testability Modulo Test Quality - Replication Package. https://doi.org/10.5281/zenodo.3740499
[49]
Fadel Touré, Mourad Badri, and Luc Lamontagne. 2014. A Metrics Suite for JUnit Test Code: A Multiple Case Study on Open Source Software. Journal of Software Engineering Research and Development 2, 1 (Dec. 2014), 14.
[50]
Fadel Touré, Mourad Badri, and Luc Lamontagne. 2014. Towards a Unified Metrics Suite for JUnit Test Cases. In International Conference on Software Engineering and Knowledge Engineering (SEKE). 115--120.
[51]
Fadel Toure, Mourad Badri, and Luc Lamontagne. 2018. Predicting Different Levels of the Unit Testing Effort of Classes Using Source Code Metrics: A Multiple Case Study on Open-Source Software. Innovations in Systems and Software Engineering 14, 1 (March 2018), 15--46.
[52]
Yves Le Traon, Farid Ouabdesselam, and Chantal Robach. 2000. Analyzing Testability on Data Flow Designs. In International Symposium on Software Reliability Engineering (ISSRE). 162--173.
[53]
Yves Le Traon and Chantal Robach. 1997. Testability Measurements for Data Flow Designs. In IEEE International Software Metrics Symposium (METRICS). 91--98.
[54]
Jeffrey M. Voas and Keith W Miller. 1995. Software Testability: The New Verification. IEEE Software 12, 3 (1995), 17--28.
[55]
Michal Young and Mauro Pezze. 2008. Software Testing and Analysis: Process, Principles and Techniques. John Wiley & Sons.
[56]
Ping Yu, Tarja Systa, and Hausi Muller. 2002. Predicting Fault-Proneness Using OO Metrics. An Industrial Case Study. In European Conference on Software Maintenance and Reengineering (ECSMR). 99--107.
[57]
T. Yu, W. Wen, X. Han, and J. H. Hayes. 2016. Predicting Testability of Concurrent Programs. In IEEE Conference on Software Testing, Validation and Verification (ICST). 168--179.
[58]
J. Zhang, L. Zhang, M. Harman, D. Hao, Y. Jia, and L. Zhang. 2019. Predictive Mutation Testing. IEEE Transactions on Software Engineering 45, 9 (2019), 898--918.

Cited By

View all
  • (2025)Testability-driven developmentComputer Standards & Interfaces10.1016/j.csi.2024.10387791:COnline publication date: 1-Jan-2025
  • (2024)Enhancing Frontend Efficiency: Reusability and Testability in Component-Driven Development2024 4th International Conference on Emerging Smart Technologies and Applications (eSmarTA)10.1109/eSmarTA62850.2024.10638895(1-8)Online publication date: 6-Aug-2024
  • (2024)Fuzzy Rule-Based Quantitative Framework for System Testability Measurement2024 IEEE International Symposium on Systems Engineering (ISSE)10.1109/ISSE63315.2024.10741143(1-4)Online publication date: 16-Oct-2024
  • Show More Cited By

Recommendations

Comments

Please enable JavaScript to view thecomments powered by Disqus.

Information & Contributors

Information

Published In

cover image ACM Conferences
ICPC '20: Proceedings of the 28th International Conference on Program Comprehension
July 2020
481 pages
ISBN:9781450379588
DOI:10.1145/3387904
Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than ACM must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected]

Sponsors

Publisher

Association for Computing Machinery

New York, NY, United States

Publication History

Published: 12 September 2020

Permissions

Request permissions for this article.

Check for updates

Author Tags

  1. Software Metrics
  2. Software Testability
  3. Test Effort
  4. Test Quality

Qualifiers

  • Research-article
  • Research
  • Refereed limited

Funding Sources

  • SNF Swiss National Foundation

Conference

ICPC '20
Sponsor:

Upcoming Conference

ICSE 2025

Contributors

Other Metrics

Bibliometrics & Citations

Bibliometrics

Article Metrics

  • Downloads (Last 12 months)64
  • Downloads (Last 6 weeks)10
Reflects downloads up to 24 Dec 2024

Other Metrics

Citations

Cited By

View all
  • (2025)Testability-driven developmentComputer Standards & Interfaces10.1016/j.csi.2024.10387791:COnline publication date: 1-Jan-2025
  • (2024)Enhancing Frontend Efficiency: Reusability and Testability in Component-Driven Development2024 4th International Conference on Emerging Smart Technologies and Applications (eSmarTA)10.1109/eSmarTA62850.2024.10638895(1-8)Online publication date: 6-Aug-2024
  • (2024)Fuzzy Rule-Based Quantitative Framework for System Testability Measurement2024 IEEE International Symposium on Systems Engineering (ISSE)10.1109/ISSE63315.2024.10741143(1-4)Online publication date: 16-Oct-2024
  • (2024)Measuring Software Testability via Automatically Generated Test CasesIEEE Access10.1109/ACCESS.2024.339662512(63904-63916)Online publication date: 2024
  • (2024)Measuring and improving software testability at the design levelInformation and Software Technology10.1016/j.infsof.2024.107511174:COnline publication date: 1-Oct-2024
  • (2024)Testing the past: can we still run tests in past snapshots for Java projects?Empirical Software Engineering10.1007/s10664-024-10530-z29:5Online publication date: 30-Jul-2024
  • (2024)Natural language requirements testability measurement based on requirement smellsNeural Computing and Applications10.1007/s00521-024-09730-x36:21(13051-13085)Online publication date: 1-Jul-2024
  • (2024)Sustainable software engineering—A contribution puzzle of different teams in large IT organizationsJournal of Software: Evolution and Process10.1002/smr.267736:9Online publication date: 16-Sep-2024
  • (2023)Improving Mobile Application GUI Testability with Deep Learning-based Test Case Generation2023 International Workshop on Artificial Intelligence and Image Processing (IWAIIP)10.1109/IWAIIP58158.2023.10462806(28-33)Online publication date: 1-Dec-2023
  • (2023)Testability Refactoring in Pull Requests: Patterns and Trends2023 IEEE/ACM 45th International Conference on Software Engineering (ICSE)10.1109/ICSE48619.2023.00131(1508-1519)Online publication date: May-2023
  • Show More Cited By

View Options

Login options

View options

PDF

View or Download as a PDF file.

PDF

eReader

View online with eReader.

eReader

Media

Figures

Other

Tables

Share

Share

Share this Publication link

Share on social media