SORTIE C++ Test Documentation
Public Member Functions | Protected Member Functions | List of all members
clTestStormDirectKiller Class Reference

Tests the clStormDirectKiller class. More...

#include <TestStormDirectKiller.h>

Inheritance diagram for clTestStormDirectKiller:

Public Member Functions

void TestStormDirectKiller ()
 Assembles all other testing functions into one test.
 

Protected Member Functions

void TestNormalProcessingRun1 (clSimManager *p_oSimManager)
 Tests normal processing.
 
void TestErrorProcessing (clSimManager *p_oSimManager)
 Tests error processing.
 
const char * WriteXMLFile1 ()
 Writes the parameter file for TestNormalProcessing1().
 
const char * WriteXMLErrorFile1 ()
 Writes an error file where the storm behavior is not also enabled.
 
const char * WriteXMLErrorFile2 ()
 Writes an error file where mortality behaviors aren't applied to all storm trees.
 

Detailed Description

Tests the clStormDirectKiller class.

Member Function Documentation

void clTestStormDirectKiller::TestErrorProcessing ( clSimManager *  p_oSimManager)
protected

Tests error processing.

Exceptions
errorif any of the errors are not caught, or an error other than the intended error is thrown by a parameter file.
void clTestStormDirectKiller::TestNormalProcessingRun1 ( clSimManager *  p_oSimManager)
protected

Tests normal processing.

WriteXMLFile1() writes the parameter file. Aspects of the run:

  • 4 species.
  • Plot size 50X50.
  • Behavior applied to seedlings, saplings, and adults of species 1 and 4, adults only of species 2, none of species 3.
  • Susceptibility map - 25X25 m cells; 0 in southern half of the plot, 1 in northern half.
  • 1000 each of seedlings, saplings, and adults of each species, on each half of the plot.
  • Timestep 1: No storms.
  • Timestep 2: Storm of 0.2.
  • Timestep 3: No storms.
  • Timestep 4: Storm of 0.5 and 0.6.

The run proceeds for 5 timesteps and the number of trees with each damage counter is checked through time.

Parameters
p_oSimManagerSim Manager object to run our test run.
void clTestStormDirectKiller::TestStormDirectKiller ( )

Assembles all other testing functions into one test.

const char* clTestStormDirectKiller::WriteXMLErrorFile1 ( )
protected

Writes an error file where the storm behavior is not also enabled.

Returns
File name of the freshly written parameter file.
const char* clTestStormDirectKiller::WriteXMLErrorFile2 ( )
protected

Writes an error file where mortality behaviors aren't applied to all storm trees.

Returns
File name of the freshly written parameter file.
const char* clTestStormDirectKiller::WriteXMLFile1 ( )
protected

Writes the parameter file for TestNormalProcessing1().

Returns
File name of the freshly written parameter file.

The documentation for this class was generated from the following file: