The following is an example of adding a trusted keyword entry to a test description file.

CODE EXAMPLE 4-15 trusted Keyword Entry

<TR>

<TD SCOPE="row"> <B>keywords</B> </TD> <TD>trusted</TD>

</TR>

When other keywords (such as positive) are used, they are included in the same line as the trusted keyword and separated by white space.

Using an Attribute to Mark Double-Duty Tests

When developing double-duty tests, test writers should use the DoubleDutySecurity attribute with the value set to yes in the test description to mark these tests. Tests that have a DoubleDutySecurity attribute with a value of yes in their test description file are selected and executed in both the trusted and the untrusted security modes.

The following is an example of a DoubleDutySecurity attribute with a value of yes added to a test description file.

CODE EXAMPLE 4-16DoubleDutySecurity Attribute

<TR>

<TD SCOPE="row"> <B>DoubleDutySecurity</B> </TD> <TD> yes </TD>

</TR>

The following is an example of a test description file for a double-duty test.

CODE EXAMPLE 4-17Test Description for a Double Duty Test

<TITLE>Test Specifications and Descriptions for Test</TITLE> </HEAD>

<BODY>

<H1>Test Specifications and Descriptions for Test</H1> <HR>

<a name="Test"></a>

<TABLE BORDER=1 SUMMARY="JavaTest Test Description" CLASS= TestDescription>

Chapter 4 Writing Tests 63

Page 83
Image 83
Sun Microsystems 1.2 manual Using an Attribute to Mark Double-Duty Tests