<p>Asserts provide the ability to automatically validate complex results.
There are two types of asserts here - the first are a set of commands that are
included in the input files and tell the code what
answer to expect, and the second are C++ language macros that are part of the
source and confirm the internal decisions made
by the code. To avoid confusion, the first type of asserts have been renamed to monitors since C10.</p>
<p>All of the files in the test suite include <b>monitor</b> commands. The <fontsize="3"><b><kbd> monitor</kbd></b></font> command is described in the <b>Miscellaneous Commands</b> section of
<b>Hazy I</b>, and
provides the infrastructure needed for
complete automatic testing of the code. This command tells the code what answer to
expect. If the computed results do not agree then the code prints a
standard comment and exits with an
error condition. These <b>monitor</b> commands have nothing to do with the
simulation itself, and would not be included in an actual calculation. You
should ignore them, or even delete all of them (a Perl script,
tests_remove_asserts.pl, is provided is provided as part of the test suite to do
this).</p>
<p>The source code also includes many C++ <fontsize="3"><b><kbd>assert</kbd></b></font> macros that are designed to validate the code's
internal decisions. The <fontsize="3"><b><kbd>assert</kbd></b></font> macro only exists if the NDEBUG macro is
not set when the code is compiled. (If the NDEBUG macro is set then
<fontsize="3"><b><kbd>assert</kbd></b></font>
macros within the source are ignored by the compiler.) The test cases
should be run at least once with the <fontsize="3"><b><kbd>assert</kbd></b></font> macro active, that is, do not
include a compiler option to define the NDEBUG macro. In most compilers
the NDEBUG macro is set when compiler optimization is set to a high level.
In practice this means that the entire code should be compiled with only low
optimization and the tests computed to validate the platform. Then
recompile with higher optimization for production runs, and recompute the test
<p>When executed as a stand-alone program the code expects to read commands from
standard input and write results to standard output. I compute single models by defining a shell script called "<fontsize="3"><b><kbd>run</kbd></b></font><code>".</code>
It is described in more detail in the <ahref="http://wiki.nublado.org/wiki/RunningC13">Cloudy wiki</a></p>