util.hpp 454 Bytes
Newer Older
incardon's avatar
incardon committed
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
/*
 * util.hpp
 *
 *  Created on: Nov 20, 2014
 *      Author: Pietro Incardona
 */

/*! \brief check that two array match
 *
 * check that two array match
 *
 * \param ptr1 Point to array 1
 * \param ptr2 Pointer to array 2
 * \param sz Size of the array
 *
 */

template<typename T> void boost_check_array(const T * ptr1, const T * ptr2, size_t sz)
{
	// Check the array
	for (int i = 0 ; i < sz ; i++)
	{
		BOOST_REQUIRE_EQUAL(ptr1[i],ptr2[i]);
	}
}