Printing a test report

PrintTestReport allows you to see the results for tests that have been logged using the -log option in RunTest. PrintTestReport accepts the following options on the console command line:

Option Description
-e[cho] h|g|n|d|D Sets detail of diagnostic output: headline, general, normal, detail, Debug; specifies the echo level for printing the diagnostic output from the tests.
-f[ail] Shows failing tests only. By default, prints all tests logged.
-file <fileName> Uses the log file fileName.
-k[ey] key [value] Specifies a key and a value to retrieve a more specific subset of the tests. For example, you could search the log for all tests with key = kTargetSharedLibraryKey and value = HighLevelToolBox to retrieve all tests run on high level Toolbox. Define the key-value pairs for a test in the CopyInfo member function.
-p[ass] Shows passing tests only. By default, prints all tests logged.
-s[ummary] Prints a summary for all tests logged, including the total number of tests, the number of tests that passed, and the number of tests that failed.

Here is an example of the default output from the PrintTestReport command for a sample test suite:

      ========================================================
      Report from "TestLog"
      ========================================================
      
      Test TSampleObjectStringTest ( Pass ) {TSampleObjectBaseTest::Test()
          fTextOption = George
          TextInBuffer = George
          myText2 = George
      }
      Test TSampleObjectLengthTest ( Pass ) {TSampleObjectLengthTest::Test()
          fIntegerOption = 66
          maxlength = 66
      }
      Test TSampleObjectOutputLogTest ( Pass ) {This is information about the test.
      
      Loop completed 10 cycles.
      }
      Test TSampleObjectOutputLogTest ( Pass ) {
      This is information about the test.
      
      Loop completed 10 cycles.
      }
      Number of tests, total  = 22
                       passed = 22
                       failed = 0

[Contents] [Previous] [Next]
Click the icon to mail questions or corrections about this material to Taligent personnel.
Copyright©1995 Taligent,Inc. All rights reserved.

Generated with WebMaker