clTestPuertoRicoEstablishment Class Reference

Tests the clPuertoRicoEstablishment class. More...

#include <TestPuertoRicoEstablishment.h>

List of all members.

Public Member Functions

void TestPuertoRicoEstablishment ()
 Tests the clPuertoRicoEstablishment class.

Protected Member Functions

void TestNormalProcessing (clSimManager *p_oSimManager)
 This tests normal processing.
void TestErrorProcessing (clSimManager *p_oSimManager)
 Tests error processing.
char * WriteXMLFile1 ()
 Writes a setup file.
char * WriteXMLErrorFile1 ()
 Writes a file where a light extinction coefficient is not between 0 and 1.
char * WriteXMLErrorFile2 ()
 Writes a file where the value for m_fLightHeight is not zero or greater.
char * WriteXMLErrorFile3 ()
 Writes a file where the value for mp_fOptimumGLI is not between 0 and 100.
char * WriteXMLErrorFile4 ()
 Writes a file where there is no disperse behavior.
char * WriteXMLErrorFile5 ()
 Writes a file where there is no storm behavior.
char * WriteXMLErrorFile6 ()
 Writes a file where the number of altitude angles is less than 1.
char * WriteXMLErrorFile7 ()
 Writes a file where the number of azimuth angles is less than 1.
void WriteCommonStuff (std::fstream &oOut)
 Writes common portions of the test parameter files (tree pop, plot, etc).


Detailed Description

Tests the clPuertoRicoEstablishment class.


Member Function Documentation

void clTestPuertoRicoEstablishment::TestErrorProcessing clSimManager *  p_oSimManager  )  [protected]
 

Tests error processing.

It checks for the following errors:

  • Any of the light extinction coefficient values are not between 0 and 1.
  • The value for m_fLightHeight is not zero or greater
  • The value for mp_fOptimumGLI is not between 0 and 100.
  • There is no disperse behavior enabled.

void clTestPuertoRicoEstablishment::TestNormalProcessing clSimManager *  p_oSimManager  )  [protected]
 

This tests normal processing.

A plot is set up and a set of trees added designed to give target GLI values to certain "Dispersed Seed" grid cells. Mostly there is only one neighbor, and the trees are placed such that the GLI point is completely within their canopies, to make test calculations easy. (GLI calculations themselves don't need testing here.) A given number of seeds of species 2, 3, and 4 is added to each of 9 grid cells. The run goes, and then we check that the appropriate number of seedlings of each species in each cell exists. WriteXMLFile1() writes the parameter file.

Parameters:
p_oSimManager Sim Manager object.

void clTestPuertoRicoEstablishment::WriteCommonStuff std::fstream &  oOut  )  [protected]
 

Writes common portions of the test parameter files (tree pop, plot, etc).

Parameters:
oOut File stream to write to.

char* clTestPuertoRicoEstablishment::WriteXMLErrorFile1  )  [protected]
 

Writes a file where a light extinction coefficient is not between 0 and 1.

Returns:
Filename written.

char* clTestPuertoRicoEstablishment::WriteXMLErrorFile2  )  [protected]
 

Writes a file where the value for m_fLightHeight is not zero or greater.

Returns:
Filename written.

char* clTestPuertoRicoEstablishment::WriteXMLErrorFile3  )  [protected]
 

Writes a file where the value for mp_fOptimumGLI is not between 0 and 100.

Returns:
Filename written.

char* clTestPuertoRicoEstablishment::WriteXMLErrorFile4  )  [protected]
 

Writes a file where there is no disperse behavior.

Returns:
Filename written.

char* clTestPuertoRicoEstablishment::WriteXMLErrorFile5  )  [protected]
 

Writes a file where there is no storm behavior.

Returns:
Filename written.

char* clTestPuertoRicoEstablishment::WriteXMLErrorFile6  )  [protected]
 

Writes a file where the number of altitude angles is less than 1.

Returns:
Filename written.

char* clTestPuertoRicoEstablishment::WriteXMLErrorFile7  )  [protected]
 

Writes a file where the number of azimuth angles is less than 1.

Returns:
Filename written.

char* clTestPuertoRicoEstablishment::WriteXMLFile1  )  [protected]
 

Writes a setup file.

This contains 4 species, one unused (species 1; this helps catch array-index problems). Non-spatial disperse is applied to adults of all species, with values such that no seeds will be dispersed from any trees. Species 2-4 get Puerto Rico establishment.

Returns:
Filename written.


The documentation for this class was generated from the following file:
Generated on Mon Mar 27 15:13:46 2006 for SORTIE C++ Test Documentation by  doxygen 1.4.6-NO