Emotional Impact in Test Quality: A Sentiment Analysis on the Introduction of Test Smells in Dart Projects
The quality of software tests plays a critical role in ensuring system reliability and maintainability. However, the introduction of poor practices, known as test smells, can compromise the effectiveness of tests and, consequently, the quality of the project. This study explores developers’ emotional states related to the introduction of test smells in projects developed in the Dart language through sentiment analysis of commit messages. We investigate whether developers express emotional reactions in their messages when introducing or handling test smells in the code and how these emotions may reflect behavioral patterns, such as frustration, urgency, or satisfaction, associated with the introduction or resolution of these antipatterns. The analysis was conducted on a dataset of commits from various Dart repositories, aiming to identify predominant emotions and emotional polarity patterns related to each type of test smell. We seek to map specific emotions to common antipatterns, such as frustration associated with Assertion Roulette or impatience with Mystery Guest. Our results provide insights into the psychological and emotional aspects present in software development, highlighting the importance of an emotionally healthy environment for test quality practices. Moreover, this research offers support for developing practices and tools that encourage the reduction of test smells, promoting a more satisfying development experience and the continuous improvement of software quality.