Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
skip to main content
article

CUTE: a concolic unit testing engine for C

Published: 01 September 2005 Publication History

Abstract

In unit testing, a program is decomposed into units which are collections of functions. A part of unit can be tested by generating inputs for a single entry function. The entry function may contain pointer arguments, in which case the inputs to the unit are memory graphs. The paper addresses the problem of automating unit testing with memory graphs as inputs. The approach used builds on previous work combining symbolic and concrete execution, and more specifically, using such a combination to generate test inputs to explore all feasible execution paths. The current work develops a method to represent and track constraints that capture the behavior of a symbolic execution of a unit with memory graphs as inputs. Moreover, an efficient constraint solver is proposed to facilitate incremental generation of such test inputs. Finally, CUTE, a tool implementing the method is described together with the results of applying CUTE to real-world examples of C code.

References

[1]
T. Ball. Abstraction-guided test generation: A case study. Technical Report MSR-TR-2003-86, Microsoft Research.
[2]
C. W. Barrett and S. Berezin. CVC Lite: A new implementation of the cooperating validity checker. In Proc. 16th International Conference on Computer Aided Verification, pages 515--518, July 2004.
[3]
D. Beyer, A. J. Chlipala, T. A. Henzinger, R. Jhala, and R. Majumdar. Generating Test from Counterexamples. In Proc. of the 26th ICSE, pages 326--335, 2004.
[4]
D. Bird and C. Munoz. Automatic Generation of Random Self-Checking Test Cases. IBM Systems Journal, 22(3):229--245, 1983.
[5]
C. Boyapati, S. Khurshid, and D. Marinov. Korat: Automated testing based on Java predicates. In Proc. of International Symposium on Software Testing and Analysis, pages 123--133, 2002.
[6]
C. Cadar and D. Engler. Execution generated test cases: How to make systems code crash itself. In Proc. of SPIN Workshop, 2005.
[7]
K. Claessen and J. Hughes. Quickcheck: A lightweight tool for random testing of Haskell programs. In Proc. of 5th ACM SIGPLAN International Conference on Functional Programming (ICFP), pages 268--279, 2000.
[8]
C. Csallner and Y. Smaragdakis. JCrasher: an automatic robustness tester for Java. Software: Practice and Experience, 34:1025--1050, 2004.
[9]
C. Csallner and Y. Smaragdakis. Check 'n' Crash: Combining static checking and testing. In 27th International Conference on Software Engineering, 2005.
[10]
J. E. Forrester and B. P. Miller. An Empirical Study of the Robustness of Windows NT Applications Using Random Testing. In Proceedings of the 4th USENIX Windows System Symposium, 2000.
[11]
P. Godefroid, N. Klarlund, and K. Sen. DART: Directed automated random testing. In Proc. of the ACM SIGPLAN 2005 Conference on Programming Language Design and Implementation (PLDI), 2005.
[12]
W. Grieskamp, Y. Gurevich, W. Schulte, and M. Veanes. Generating finite state machines from abstract state machines. In Proc. International Symposium on Software Testing and Analysis, pages 112--122, 2002.
[13]
N. Gupta, A. P. Mathur, and M. L. Soffa. Generating test data for branch coverage. In Proc. of the International Conference on Automated Software Engineering, pages 219--227, 2000.
[14]
S. Khurshid, C. S. Pasareanu, and W. Visser. Generalized symbolic execution for model checking and testing. In Proc. 9th Int. Conf. on TACAS, pages 553--568, 2003.
[15]
B. Korel. A dynamic Approach of Test Data Generation. In IEEE Conference on Software Maintenance, pages 311--317, November 1990.
[16]
E. Larson and T. Austin. High coverage detection of input-related security faults. In Proc. of the 12th USENIX Security Symposium (Security '03), Aug. 2003.
[17]
lp_solve. http://groups.yahoo.com/group/lp_solve/.
[18]
J. McCarthy and J. Painter. Correctness of a compiler for arithmetic expressions. In Proceedings of Symposia in Applied Mathematics. AMS, 1967.
[19]
G. C. Necula, S. McPeak, S. P. Rahul, and W. Weimer. CIL: Intermediate Language and Tools for Analysis and transformation of C Programs. In Proceedings of Conference on compiler Construction, pages 213--228, 2002.
[20]
J. Offut and J. Hayes. A Semantic Model of Program Faults. In Proc. of ISSTA'96, pages 195--200, 1996.
[21]
C. Pacheco and M. D. Ernst. Eclat: Automatic generation and classification of test inputs. In 19th European Conference Object-Oriented Programming, 2005.
[22]
Parasoft. Jtest manuals version 6.0. Online manual, February 2005. http://www.parasoft.com/.
[23]
C. S. Pasareanu, M. B. Dwyer, and W. Visser. Finding feasible counter-examples when model checking abstracted java programs. In Proc. of TACAS'01, pages 284--298, 2001.
[24]
K. Sen, D. Marinov, and G. Agha. CUTE: A concolic unit testing engine for C. Technical Report UIUCDCS-R-2005-2597, UIUC, 2005.
[25]
SGLIB. http://xref-tech.com/sglib/main.html.
[26]
Valgrind. http://valgrind.org/.
[27]
W. Visser, C. S. Pasareanu, and S. Khurshid. Test input generation with Java PathFinder. In Proc. 2004 ACM SIGSOFT International Symposium on Software Testing and Analysis, pages 97--107, 2004.
[28]
S. Visvanathan and N. Gupta. Generating test data for functions with pointer inputs. In 17th IEEE International Conference on Automated Software Engineering, 2002.
[29]
T. Xie, D. Marinov, and D. Notkin. Rostra: A framework for detecting redundant object-oriented unit tests. In Proc. 19th IEEE International Conference on Automated Software Engineering, pages 196--205, Sept. 2004.
[30]
T. Xie, D. Marinov, W. Schulte, and D. Notkin. Symstra: A framework for generating object-oriented unit tests using symbolic execution. In Proc. of the Tools and Algorithms for the Construction and Analysis of Systems, 2005.

Cited By

View all
  • (2025)LLM-enhanced evolutionary test generation for untyped languagesAutomated Software Engineering10.1007/s10515-025-00496-732:1Online publication date: 17-Feb-2025
  • (2025)Leveraging Program Structure for Test Case GenerationAutomated Technology for Verification and Analysis10.1007/978-3-031-78750-8_7(137-157)Online publication date: 12-Feb-2025
  • (2024)Supporting the debugging of Erlang programs by symbolic executionActa Universitatis Sapientiae, Informatica10.47745/ausi-2024-000416:1(44-61)Online publication date: 2-Oct-2024
  • Show More Cited By

Recommendations

Comments

Information & Contributors

Information

Published In

cover image ACM SIGSOFT Software Engineering Notes
ACM SIGSOFT Software Engineering Notes  Volume 30, Issue 5
September 2005
462 pages
ISSN:0163-5948
DOI:10.1145/1095430
Issue’s Table of Contents
  • cover image ACM Conferences
    ESEC/FSE-13: Proceedings of the 10th European software engineering conference held jointly with 13th ACM SIGSOFT international symposium on Foundations of software engineering
    September 2005
    402 pages
    ISBN:1595930140
    DOI:10.1145/1081706
Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than ACM must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected]

Publisher

Association for Computing Machinery

New York, NY, United States

Publication History

Published: 01 September 2005
Published in SIGSOFT Volume 30, Issue 5

Check for updates

Author Tags

  1. concolic testing
  2. data structure testing
  3. explicit path model-checking
  4. random testing
  5. testing C programs
  6. unit testing

Qualifiers

  • Article

Contributors

Other Metrics

Bibliometrics & Citations

Bibliometrics

Article Metrics

  • Downloads (Last 12 months)192
  • Downloads (Last 6 weeks)32
Reflects downloads up to 07 Mar 2025

Other Metrics

Citations

Cited By

View all
  • (2025)LLM-enhanced evolutionary test generation for untyped languagesAutomated Software Engineering10.1007/s10515-025-00496-732:1Online publication date: 17-Feb-2025
  • (2025)Leveraging Program Structure for Test Case GenerationAutomated Technology for Verification and Analysis10.1007/978-3-031-78750-8_7(137-157)Online publication date: 12-Feb-2025
  • (2024)Supporting the debugging of Erlang programs by symbolic executionActa Universitatis Sapientiae, Informatica10.47745/ausi-2024-000416:1(44-61)Online publication date: 2-Oct-2024
  • (2024)Finding ∀∃ Hyperbugs using Symbolic ExecutionProceedings of the ACM on Programming Languages10.1145/36897618:OOPSLA2(1420-1445)Online publication date: 8-Oct-2024
  • (2024)Program Environment FuzzingProceedings of the 2024 on ACM SIGSAC Conference on Computer and Communications Security10.1145/3658644.3690229(720-734)Online publication date: 2-Dec-2024
  • (2024)Define-Use Guided Path Exploration for Better Forced ExecutionProceedings of the 33rd ACM SIGSOFT International Symposium on Software Testing and Analysis10.1145/3650212.3652128(287-299)Online publication date: 11-Sep-2024
  • (2024)Code-Aware Prompting: A Study of Coverage-Guided Test Generation in Regression Setting using LLMProceedings of the ACM on Software Engineering10.1145/36437691:FSE(951-971)Online publication date: 12-Jul-2024
  • (2024)WeBridge: Synthesizing Stored Procedures for Large-Scale Real-World Web ApplicationsProceedings of the ACM on Management of Data10.1145/36393192:1(1-29)Online publication date: 26-Mar-2024
  • (2024)Marco: A Stochastic Asynchronous Concolic ExplorerProceedings of the IEEE/ACM 46th International Conference on Software Engineering10.1145/3597503.3623301(1-12)Online publication date: 20-May-2024
  • (2024)A Survey of Software Dynamic Analysis MethodsProgramming and Computing Software10.1134/S036176882401007950:1(90-114)Online publication date: 1-Feb-2024
  • Show More Cited By

View Options

Login options

View options

PDF

View or Download as a PDF file.

PDF

eReader

View online with eReader.

eReader

Figures

Tables

Media

Share

Share

Share this Publication link

Share on social media