Advanced Search
    He Yanxiang, Chen Yong, Wu Wei, Xu Chao, and Wu Libing. Automatically Generating Error-Traceable Test Cases Based on Compiler[J]. Journal of Computer Research and Development, 2012, 49(9): 1843-1851.
    Citation: He Yanxiang, Chen Yong, Wu Wei, Xu Chao, and Wu Libing. Automatically Generating Error-Traceable Test Cases Based on Compiler[J]. Journal of Computer Research and Development, 2012, 49(9): 1843-1851.

    Automatically Generating Error-Traceable Test Cases Based on Compiler

    • Automatic test case generation is an important guarantee to achieve automated testing and to verify the trustness of software. After analyzing the existing methods of automatic test case generation, we propose a compiler-based error-traceable method to generate the test cases automatically. This method relies on the compiler and inserts the test requirements into the source codes properly by expanding the existing syntax and semantics of the source codes. Therefore, when the code generator generates the object codes, it can generate simultaneously the test cases according to the results of the testing requirement analysis. This method unifies the test case generation and the object code generation and brings them in the compiler. By doing this, we can avoid the overhead of information transferring interface commonly included in the situation, in which we develop a single automatic test cases generator that uses the information of another compilers analysis. At the same time, when the test case cannot pass, it is very convenient for the programmer to correct the errors of their codes because the error positions can be found quickly by the error tracking information of the source codes. Finally, a sample program illustrates the concrete process of this method and proves that the method is effective.
    • loading

    Catalog

      Turn off MathJax
      Article Contents

      /

      DownLoad:  Full-Size Img  PowerPoint
      Return
      Return