Abstract
There are many difficulties associated with developing correct multithreaded software, and many of the activities that are simple for single threaded software are exceptionally hard for multithreaded software. One such example is constructing unit tests involving multiple threads. Given, for example, a blocking queue implementation, writing a test case to show that it blocks and unblocks appropriately using existing testing frameworks is exceptionally hard. In this paper, we describe the MultithreadedTC framework which allows the construction of deterministic and repeatable unit tests for concurrent abstractions. This framework is not designed to test for synchronization errors that lead to rare probabilistic faults under concurrent stress. Rather, this framework allows us to demonstrate that code does provide specific concurrent functionality (e.g., a thread attempting to acquire a lock is blocked if another thread has the lock). We describe the framework and provide empirical comparisons against hand-coded tests designed for Sun's Java concurrency utilities library and against previous frameworks that addressed this same issue. The source code for this framework is available under an open source license. Copyright 2007 ACM.
Author supplied keywords
Cite
CITATION STYLE
Pugh, W., & Ayewah, N. (2007). Unit testing concurrent software. In ASE’07 - 2007 ACM/IEEE International Conference on Automated Software Engineering (pp. 513–516). https://doi.org/10.1145/1321631.1321722
Register to see more suggestions
Mendeley helps you to discover research relevant for your work.