Modern software systems are frequently developed and tested across multiple platforms (e.g., Windows, Linux, and macOS). In the software testing context, practitioners adapt the tests to run differently according to the target platform. These tests, which need to identify the platform on which they will be executed, are referred to as OS-specific tests. In this paper, we present an empirical study to evaluate how developers implement OS-specific tests in CPython, which is the reference implementation project for the Python programming language. Then, we mine this project and assess their OS-specific tests quantitatively. For this, we propose three research questions to assess the frequency, location, and issues related to OS-specific tests. Our results show that OS-specific tests are common in the CPython project, and 13% of the analyzed test files are OS-specific tests (RQ1). OS Identification APIs are used more frequently in test code (53.46%), and the test decorator @unittest.skipUnless is the most used to skip tests depending on the platform (RQ2).We also find 170 issues related to OS-specific tests in CPython, and Windows is the most targeted platform (RQ3). Lastly, we discussed practical implications for practitioners and researchers. Based on our findings, we emphasized the importance of testing across multiple platforms and examined the relationship between issues and OS-specific tests, among other insights.
Building similarity graph...
Analyzing shared references across papers
Loading...
Ricardo Job
Instituto Federal de Educação Ciência e Tecnologia da Paraíba
André Hora
Universidade Federal de Minas Gerais
Building similarity graph...
Analyzing shared references across papers
Loading...
Job et al. (Wed,) studied this question.
synapsesocial.com/papers/68d461bc31b076d99fa60b1f — DOI: https://doi.org/10.5753/sast.2025.13918
Synapse has enriched 5 closely related papers on similar clinical questions. Consider them for comparative context: