OpenFPM
5.2.0
Project that contain the implementation of distributed structures
unit_test_init_cleanup.hpp
1
/*
2
* unit_test_init_cleanup.hpp
3
*
4
* Created on: Apr 17, 2015
5
* Author: Pietro Incardona
6
*/
7
8
#ifndef UNIT_TEST_INIT_CLEANUP_HPP_
9
#define UNIT_TEST_INIT_CLEANUP_HPP_
10
11
#include "util/cuda_util.hpp"
12
14
struct
ut_start
15
{
16
18
ut_start
()
19
{
20
#ifdef CUDA_ON_CPU
21
init_wrappers();
22
#endif
23
#ifdef PERFORMANCE_TEST
24
test_dir = getenv(
"OPENFPM_PERFORMANCE_TEST_DIR"
);
25
26
if
(test_dir == NULL)
27
{
28
std::cerr <<
"Error: "
__FILE__ <<
":"
<< __LINE__ <<
" in order to run the performance test you must set the environment variable $OPENFPM_PERFORMANCE_TEST_DIR to the test or an empty directory"
;
29
exit(1);
30
}
31
#endif
32
33
}
34
36
~ut_start
()
37
{
38
}
39
};
40
41
//____________________________________________________________________________//
42
43
BOOST_GLOBAL_FIXTURE(
ut_start
);
44
45
46
47
#endif
/* UNIT_TEST_INIT_CLEANUP_HPP_ */
ut_start::ut_start
ut_start()
start procedure before running the test
Definition:
unit_test_init_cleanup.hpp:18
ut_start::~ut_start
~ut_start()
post procedure to call after the test
Definition:
unit_test_init_cleanup.hpp:36
ut_start
boost unit test fixation (start procedure to call before testing)
Definition:
unit_test_init_cleanup.hpp:15
openfpm_data
src
unit_test_init_cleanup.hpp
Generated by
1.8.17