Rotten Green Tests A First Analysis
Type de document :
Rapport de recherche: Autre communication scientifique (congrès sans actes - poster - séminaire...)
Titre :
Rotten Green Tests A First Analysis
Auteur(s) :
Delplanque, Julien [Auteur]
Analyses and Languages Constructs for Object-Oriented Application Evolution [RMOD]
Ducasse, Stephane [Auteur]
Analyses and Languages Constructs for Object-Oriented Application Evolution [RMOD]
Black, Andrew [Auteur]
Department of Computer Science [Portland] [CS]
Polito, Guillermo [Auteur]
Centre de Recherche en Informatique, Signal et Automatique de Lille - UMR 9189 [CRIStAL]
Analyses and Languages Constructs for Object-Oriented Application Evolution [RMOD]
Analyses and Languages Constructs for Object-Oriented Application Evolution [RMOD]
Ducasse, Stephane [Auteur]
Analyses and Languages Constructs for Object-Oriented Application Evolution [RMOD]
Black, Andrew [Auteur]
Department of Computer Science [Portland] [CS]
Polito, Guillermo [Auteur]
Centre de Recherche en Informatique, Signal et Automatique de Lille - UMR 9189 [CRIStAL]
Analyses and Languages Constructs for Object-Oriented Application Evolution [RMOD]
Institution :
Inria Lille Nord Europe - Laboratoire CRIStAL - Université de Lille
Portland State University, Oregon, USA
Portland State University, Oregon, USA
Date de publication :
2018-06-20
Mot(s)-clé(s) en anglais :
rotten green tests
unit tests
testing
unit tests
testing
Discipline(s) HAL :
Informatique [cs]/Langage de programmation [cs.PL]
Résumé en anglais : [en]
Unit tests are a tenant of agile programming methodologies, and are widely used to improve code quality and prevent code regression. A passing (green) test is usually taken as a robust sign that the code under test is ...
Lire la suite >Unit tests are a tenant of agile programming methodologies, and are widely used to improve code quality and prevent code regression. A passing (green) test is usually taken as a robust sign that the code under test is valid. However, we have noticed that some green tests contain assertions that are never executed; these tests pass not because they assert properties that are true, but because they assert nothing at all. We call such tests Rotten Green Tests. Rotten Green Tests represent a worst case: they report that the code under test is valid, but in fact do nothing to test that validity, beyond checking that the code does not crash. We describe an approach to identify rotten green tests by combining simple static and dynamic analyses. Our approach takes into account test helper methods, inherited helpers, and trait compositions, and has been implemented in a tool called DrTest. We have applied DrTest to several test suites in Pharo 7.0, and identified many rotten tests, including some that have been " sleeping " in Pharo for at least 5 years.Lire moins >
Lire la suite >Unit tests are a tenant of agile programming methodologies, and are widely used to improve code quality and prevent code regression. A passing (green) test is usually taken as a robust sign that the code under test is valid. However, we have noticed that some green tests contain assertions that are never executed; these tests pass not because they assert properties that are true, but because they assert nothing at all. We call such tests Rotten Green Tests. Rotten Green Tests represent a worst case: they report that the code under test is valid, but in fact do nothing to test that validity, beyond checking that the code does not crash. We describe an approach to identify rotten green tests by combining simple static and dynamic analyses. Our approach takes into account test helper methods, inherited helpers, and trait compositions, and has been implemented in a tool called DrTest. We have applied DrTest to several test suites in Pharo 7.0, and identified many rotten tests, including some that have been " sleeping " in Pharo for at least 5 years.Lire moins >
Langue :
Anglais
Collections :
Source :
Fichiers
- https://hal.archives-ouvertes.fr/hal-01819302v2/document
- Accès libre
- Accéder au document
- https://hal.archives-ouvertes.fr/hal-01819302v2/document
- Accès libre
- Accéder au document
- https://hal.archives-ouvertes.fr/hal-01819302v2/document
- Accès libre
- Accéder au document
- https://hal.archives-ouvertes.fr/hal-01819302v2/document
- Accès libre
- Accéder au document
- document
- Accès libre
- Accéder au document
- main.pdf
- Accès libre
- Accéder au document