The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

Test::STD::PerlSTD - General Perl Software Test Description (STD)

TITLE PAGE

 Gerneral Software Test Description (STD)

 for

 Perl Program Modules

 Revision: -

 Date: 2004/05/15

 Prepared for: General Public 

 Prepared by:  http://www.SoftwareDiamonds.com support@SoftwareDiamonds.com

 Classification: None

1. Scope

This general Software Test Decription (STD) for a Perl Program Module (PM). Together with a detail STD for a Perl Program Module it establishes the tests to verify the requirements of specific Perl Program Module (PM).

In order to avoid duplications (i.e boiler plates), the Perl STD is divided into this general Perl STD and a detail STD for each program module test. This is encourage if not in fact required by 490A 3.1.2

1.1 Identification

The package name Test::STDmaker::PerSTD uniquely identfies this source of this document. The source is Perl Plain Old Documentation (POD) that may be rendered into any number of different media and paper formats by POD translators.

1.2 System overview

The system is the Perl programming language software. Perl program modules extend the Perl language. The focus of this STD is the testing of a particular Perl program module.

1.3 Document overview

This general STD establishes the common procedures, conventions used to prepare and run tests to verify Perl program modules. The STD DID preprations intructions encourages automation, tailoring and allows for different types of media including data bases and software engineering tools. This general STD establishes an automation scheme based on the Test::STDmaker|Test::STDmaker module. This may or may not be suitable for delivery for a specific end-user. As per the license agreement herein, Software Diamonds, does not claim and is not reponsbile for the fitness of this general STD for any specific use or purpose.

2. REFERENCE DOCUMENTS

Tailoring renames this section to SEE ALSO and moved it to the end of the document. This is the customary location for this info for the Unix community and where the Unix community expects to find this information. A special POD translator would move this to sectin 2 and number it section 2.

3. TEST PREPARATIONS

3.x (Project-unique identifier of a test)

A STD test for this general STD and its associated detail STDs is a Perl test script where the convention is for test scripts to have an extension of .t. There must be at least one or more than one test script to verify a Perl program module. Each test script is uniquely identified by the STD program module name used to generate the test script.

3.x.1 Hardware preparation

Usually there is no hardware preparation to run a Perl test script. The detail STD for a program module establishes any exceptions.

3.x.2 Software preparation

Usually there is no Software preparation to run a Perl test script. The detail STD for a program module establishes any exceptions.

3.x.3 Other pre-test preparations

Usually there is no pre-test preparations to run a Perl test script. The detail STD for a program module establishes any exceptions.

4. TEST DESCRIPTIONS

Each test, corresponding to the 4.x paragraphs of a STD Data Item Description (DID), is covered by its own individual detail STD program module. The Test::STDmaker program module subroutines uses the data in each detail STD program module to generate the detail STD POD and a test script. The Perl convention is a test script prints a line starting with ok or not ok at the end of a Perl test (STD test case). A test case for this general STD and its associated detail STDS is, thus, the Perl code in a test script starting from the begining or the just after the test script printing a line starting with ok or not ok to and including the next printing of a line starting with ok or not ok followed by a number. The Perl test ok number is the '.y' number for a STD test case.

In the tradition of detail sheets, the detail STD program module uses a short hand notation that is used by the Test::STDmaker module to automate the generation of test scripts and other automation as follows:

 TEST DESCRIPTIONS

 ok: 1

 N: Test Name
 R: Requirements addressed:
 C: Test - Perl Code
 A: Test - Actual Results
 E: Expected test results


  ..


 ok: x

 N: Test Name
 R: Requirements addressed:
 C: Test - Perl Code
 A: Test - Actual Results
 E: Expected test results

4.x Project-unique identifier of a test

The project for this general STD is the creation of a Perl Program Module(s) (PM) and a distribution file that contains the Perl Program Modules(s) and all the test scripts necessary to verifiy the Perl Program Modules(s) meets it requirements. Each Perl test script is uniquely identified by the name of the STD program module used to generate the test script.

4.x.y Project-unique identifier of a test case

The unique indentifier of a test case is the number after ok or not ok that the test script prints at the end of executing in Perl terminology a test. The project-unique identifier for a STD test case is the name of the STD program module used to generate the test script and the ok number. The STD program moudle POD will contain a =head 2 ok: y number. Thus, where x is the name for the STD program module, the POD link test case|x/ok: y will not only uniquely identify the STD test case but also uniquely link to the STD test case (Perl test).

4.x.y.1 Requirements addressed

The R: field in the detail STD POD program module for each test case, identifies the requirements addressed.

4.x.y.2 Prerequisite conditions

The C: and QC: fields in the detail STD POD program module for each test case, identifies the test inputs.

4.x.y.3 Test inputs.

The A: field for in the detail STD sheet for each test case, identifies the test inputs.

4.x.y.4 Expected test results.

The E: field for in the detail STD sheet for each test case, identifies the requirements addressed.

4.x.y.5 Criteria for evaluating results.

The critera for evaluation is normally the ok subroutine of the Test program module that is has been in the Perl distribution from the beginning. THe ok subroutine may be overriden by the TS: field in the detail STD sheet for each test case.

4.x.y.6 Test procedure

Following standard Perl conventions, the test scripts, detail STD program module, the program module under test, and other appropriate files are bundled together in a compressed, archive file. Running a test follows normal Perl conventions as follows:

 gunzip ${BASE_DIST_FILE}.tar.gz
 tar -xf ${BASE_DIST_FILE}.tar
 perl Makefile.PL
 $make test
 $make install

Where $make is 'make' for most operating systems and 'nmake' for Windows operating systems.

5. REQUIREMENTS TRACEABILITY

The requirements traceability for a program module are established by the "REQUIREMENTS TRACEABILITY" section of a detail STD sheet for a program module. The detail STD "REQUIREMENTS TRACEABILITY" section contains a requirements to test table and a test to requirements table. The requirements and tests in the tables are POD links to the appropriate Program Module header.

6. NOTES.

This Perl Plain Old Documentation (POD) version is copyright © 2001 2003 Software Diamonds. This POD version was derived from the hard copy public domain version freely distributed by the United States Federal Government.

License

Software Diamonds permits the redistribution and use in source and binary forms, with or without modification, provided that the following conditions are met:

  1. Redistributions of source code, modified or unmodified must retain the above copyright notice, this list of conditions and the following disclaimer.

  2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.

SOFTWARE DIAMONDS, http://www.SoftwareDiamonds.com, PROVIDES THIS SOFTWARE 'AS IS' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL SOFTWARE DIAMONDS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING USE OF THIS SOFTWARE, EVEN IF ADVISED OF NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE POSSIBILITY OF SUCH DAMAGE.

< support@SoftwareDiamonds.comE <gt>

2. SEE ALSO (Referenced documents)

Test::Tech
Test
Test::Harness
Test::STDmaker::STD
Test::STDmaker::Verify
Test::STDmaker::Demo
Test::STDmaker::Check
Software Test Description
Specification Practices
Software Development

3 POD Errors

The following errors were encountered while parsing the POD:

Around line 85:

'=item' outside of any '=over'

Around line 95:

You forgot a '=back' before '=head1'

Around line 270:

Non-ASCII character seen before =encoding in '©'. Assuming CP1252