Automatic test factoring for Java
Submitted by mernst on Wed, 2011-11-30 14:35
| Title | Automatic test factoring for Java |
| Publication Type | Conference Paper |
| Year of Publication | 2005 |
| Authors | Saff D, Artzi S, Perkins JH, Ernst MD |
| Conference Name | ASE 2005: Proceedings of the 20th Annual International Conference on Automated Software Engineering |
| Date or Month Published | November 9–11 |
| Conference Location | Long Beach, CA, USA |
| Abstract | <p><em>Test factoring</em> creates fast, focused unit tests from slow system-wide tests; each new unit test exercises only a subset of the functionality exercised by the system test. Augmenting a test suite with factored unit tests should catch errors earlier in a test run. </p> <p> One way to factor a test is to introduce <em>mock objects</em>. If a test exercises a component T, which interacts with another component E (the ``environment''), the implementation of E can be replaced by a <em> mock</em>. The mock checks that T's calls to E are as expected, and it simulates E's behavior in response. We introduce an automatic technique for test factoring. Given a system test for T and E, and a record of T's and E's behavior when the system test is run, test factoring generates unit tests for T in which E is mocked. The factored tests can isolate bugs in T from bugs in E and, if E is slow or expensive, improve test performance or cost. </p> <p> Our implementation of automatic dynamic test factoring for the Java language reduces the running time of a system test suite by up to an order of magnitude.</p> |
| Downloads | PDF PostScript |
| Citation Key | SaffAPE2005 |
Last changed Mon, 2013-06-03 10:27

cs.