Design: 06.02.02/P02

This is an abstract, language-independent design. Grim details may be found in the corresponding source code. You may return to the documentation for the module containing this program design, or to the entire hierarchical table of topics covered by the PVT.


PROGRAM 2: Validity of predefined view table

CHARACTERISTICS: ynnn

OPERATOR SCRIPT: passive test.

DESIGN:

<Inquire view facilities> to determine
  npvw = number of predefined views

TEST: #SR 4 5
      "The reported number of predefined views should be at least 6."
pass/fail depending on (npvw > 5)

TEST: #SR 4 6
      "All the predefined view entries should be accessible by
       <inquire predefined view representation>."
for ivw = 0 to npvw-1
    <inquire predefined view representation> on entry #ivw
    if (error returned) then
       fail
       goto end_access
    endif
next ivw
pass

end_access:

<inquire predefined view representation> on entry #0 to determine:
   vom(4,4) = orientation matrix
   vmm(4,4) = mapping matrix
   vclm(6)  = view clipping limits
   vcid(3)  = clipping indicators

TEST: #SR 6 7
      "The orientation and mapping matrices for predefined view #0
       should both be the identity matrix."
pass/fail depending on (vom = identity matrix and
                        vmm = identity matrix )

TEST: #SR 6 7
      "The clipping limits for predefined view #0 should be [0,1]
       in all three dimensions."
pass/fail depending on (vclm = 0,1,0,1,0,1)

TEST: #SR 6 7
      "All three clipping indicators for predefined view #0
       should be CLIP."
pass/fail depending on (vcid = CLIP, CLIP, CLIP)

END PROGRAM 2