XGL Test Suite User's Guide
この本のみを検索
PDF 文書ファイルをダウンロードする

Options for Running Denizen

3

There are several options and arguments that you can supply to the run_denizen.sh script, as well as some environment variables that can help you gain more information about test failures. This chapter describes the Denizen options, arguments, and environment variables.

run_denizen.sh Options and Arguments

The run_denizen.sh script has the following usage:
run_denizen.sh [ -rgb | -index | -sm | -cm ] [testarea1, testarea2, ...]

Options

The first four options are mutually exclusive, and indicate the test type to be used. If no test type option is given, all tests for the given test areas will be run.
-rgb

  Uses only tests listed in the RGB_TESTS file in the directory for each of the
  test areas tested. These are the tests that use the RGB color window rasters.

-index

Uses only tests listed in the INDEX_TESTS file in the directory for each of the test areas tested. These are the tests that use the index color window rasters.
-sm

  Uses only tests listed in the SM_TESTS file in the directory for each of the
  test areas tested. These are the tests that use the sampling method (SM).

-cm

Uses only tests listed in the CM_TESTS file in the directory for each of the test areas tested. These are the tests that use the comparison method (CM).

Test Areas

You may provide the run_denizen.sh script with the test areas you want to test. If no test areas are provided, all test areas will be tested. The acceptable test area names are the names of the subdirectories in the testcases/ directory:
antialiasing       depth_cueing pcache                 strokefont
arc                ellip_arc         picking           system
bugs               lighting          polygon           texture
cgm                line              quadmesh          transform
circle             marker            raster            transparency
clipping           mspolygon         rectangle         trilist
colormap           nubs              set_get_attr tristrip
context

Errors

The most common error encountered by Denizen users is the improper setting of environment variables. For example, if you forget to set $DENIZENHOME, you will receive a "not found" error message.
Another common error is not setting $FB_NAME. Also, remember to update $LD_LIBRARY_PATH if you change $XGLHOME.

More Environment Variables

Several additional environment variables can be used. They are listed in Table 3-1.
Table 3-1
Environment VariableMeaning
MAXFAILA positive integer indicating the number of failures Denizen will allow before aborting the test run. If not specified, the default value is 5.
VERBOSITYA number from 1 to 5 that determines the amount of status messages Denizen displays and stores in the log. The default is 1. A value of 5 will print all detailed status messages.
FB_DEVThe device driver of the device being tested, for example /dev/cgthree0. This environment variable must be set on two-headed systems to indicate which device driver to use. On a single-headed machine it does not have to be set.

Test Run Examples

  1. Change directories to $DENIZENHOME.

    If $DENIZENHOME is not set, set it to the full path name of the local denizen directory.


  hostname% setenv DENIZENHOME /opt/sunwddk/xgl/src/test_suite/denizen  
  hostname% cd $DENIZENHOME  

  1. Set up the environment for your denizen run, and invoke run_denizen.sh

    This step can be as complicated or simple as you need. Several examples are shown below.

Required environment variables:

  hostname% setenv DENIZENHOME /opt/sunwddk/xgl/src/test_suite/denizen  
  hostname% setenv XGLHOME /opt/SUNWits/graphics-sw/xgl  
  hostname% setenv OPENWINHOME /usr/openwin  
  hostname% setenv LD_DIBRARY_PATH $XGLHOME/lib:$OPENWINHOME/lib:$DENIZENHOME/lib  
  hostname% setenv FB_NAME cg3  
  hostname% setenv REFIMAGE $DENIZENHOME/images/refimages-cg3  
  hostname% setenv CURIMAGE /tmp  

Optional environment variables:

  hostname% setenv MAXFAIL 20  
  hostname% setenv VERBOSITY 3  
  hostname% setenv DENIZEN_DESTDIR $DENIZENHOME  

  1. Run Denizen

    Here are several examples of ways to run Denizen. If you are running Denizen from a directory other than $DENIZENHOME, add $DENIZENHOME/ in front of the example commands below.

    Running all Denizen tests:


  hostname% run_denizen.sh  

Running tests in selected test areas:

  hostname% run_denizen.sh transform lighting  

Running only the SM tests in selected test areas. If you use this option, you do not have to set the $REFIMAGE and $CURIMAGE environment variables.

  hostname% run_denizen.sh -sm arc line  

Running the comparison method tests only. The $REFIMAGE and $CURIMAGE environment variables must be set if you use this option.

  hostname% run_denizen.sh -cm  

Running an individual test. Setting $VERBOSITY to 3 and $MAXFAIL to 20 gives you more information. You must set $FB_NAME when running individual tests.

  hostname% setenv FB_NAME cg3  
  hostname% cd testcases/arc  
  hostname% arc4  

Test Make Example

This section describes how to build individual Denizen tests. Note that to build Denizen, you need the XGL include files that are available with the SDK. In each test area, there is a Makefile that will make the tests on an individual basis. If you intend to build the tests, you must modify the include Makefile, common_flags.mk, so that CC and LD point to the correct compiler and loader.
Again, $DENIZENHOME and $FB_NAME must be set. To make the individual test, change to the test area directory and type make test_name.

  hostname% cd testcases/line  
  hostname% make line2