ReFRACtor
FullPhysics::GlobalFixture Class Reference

This is a global fixture that is available to all unit tests. More...

#include <global_fixture.h>

+ Inheritance diagram for FullPhysics::GlobalFixture:
+ Collaboration diagram for FullPhysics::GlobalFixture:

Public Member Functions

 GlobalFixture ()
 Setup for all unit tests. More...
 
virtual ~GlobalFixture ()
 Teardown for all unit tests. More...
 
std::string absco_4d_dir () const
 Location of absco 4d table. More...
 
std::string absco_data_dir () const
 Location of absco table. More...
 
void add_file_to_cleanup (const std::string &Fname)
 
std::string input_dir () const
 Directory where input data such as static input files and default Lua configuration files are located. More...
 
std::string merra_data_dir () const
 Location of merra data. More...
 
std::string test_data_dir () const
 Directory where test data is. More...
 
void turn_on_logger () const
 Normally log messages don't go anywhere, so we don't clutter our unit test output. More...
 

Detailed Description

This is a global fixture that is available to all unit tests.

Definition at line 10 of file global_fixture.h.

Constructor & Destructor Documentation

◆ GlobalFixture()

GlobalFixture::GlobalFixture ( )

Setup for all unit tests.

Definition at line 16 of file global_fixture.cc.

◆ ~GlobalFixture()

GlobalFixture::~GlobalFixture ( )
virtual

Teardown for all unit tests.

Definition at line 34 of file global_fixture.cc.

Member Function Documentation

◆ absco_4d_dir()

std::string GlobalFixture::absco_4d_dir ( ) const

Location of absco 4d table.

Note that all of the Absco is going to be 4d in the future, so this can eventually go away. But for now most of the unit tests are 3d except for the few depending on the newer 4d tables.

Definition at line 140 of file global_fixture.cc.

◆ absco_data_dir()

std::string GlobalFixture::absco_data_dir ( ) const

Location of absco table.

Definition at line 101 of file global_fixture.cc.

◆ add_file_to_cleanup()

void FullPhysics::GlobalFixture::add_file_to_cleanup ( const std::string &  Fname)
inline

Definition at line 23 of file global_fixture.h.

◆ input_dir()

std::string GlobalFixture::input_dir ( ) const

Directory where input data such as static input files and default Lua configuration files are located.

Definition at line 63 of file global_fixture.cc.

◆ merra_data_dir()

std::string GlobalFixture::merra_data_dir ( ) const

Location of merra data.

Definition at line 119 of file global_fixture.cc.

◆ test_data_dir()

std::string GlobalFixture::test_data_dir ( ) const

Directory where test data is.

This already includes the trailing slash, so you can just do test_data_data() + "foo.txt" in your unit tests.

Definition at line 83 of file global_fixture.cc.

◆ turn_on_logger()

void GlobalFixture::turn_on_logger ( ) const

Normally log messages don't go anywhere, so we don't clutter our unit test output.

But in some cases you may want to the logger turned on. This automatically gets turned off again at the end of the unit test.

Definition at line 52 of file global_fixture.cc.


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

Copyright © 2017, California Institute of Technology.
ALL RIGHTS RESERVED.
U.S. Government Sponsorship acknowledged.
Generated Fri Aug 24 2018 15:44:12