| Now, scale of software systems is larger and larger, an increasingnumber of complexity. Results are more serious because of software errors. Quality and reliability of software have been recognized. In modern software engineering, software should be made strict quality valuation and testing in every phase of software developing. Software testing has become key phase for guaranteeing quality.This paper researches on automatic testing of object-oriented (OO) software, especially one method of static testing base on code. Main contents include software-testing method classifying, OO software testing, testing based on program code, static testing model and practice frame of program static analysis.For character of C++ program, we advise a basic designed frame and developing procedure of static analyses method of C++ program, then have simply developed by VC++, finally present an example. The method's main designed idea is that analyzing C++ source code file, finding class relation information, saving the results to database table, finally displaying class diagram as UML criterion. Software tester can quickly and clearly to understand program structure and effectively to develop testing case. |