GCC Code Coverage Report


Directory: ./
File: tmp_project/PhoenixCore/src/phoenix_check_impl.h
Date: 2025-03-14 11:54:19
Exec Total Coverage
Lines: 7 7 100.0%
Branches: 4 6 66.7%

Line Branch Exec Source
1 /***************************************
2 Auteur : Pierre Aubert
3 Mail : pierre.aubert@lapp.in2p3.fr
4 Licence : CeCILL-C
5 ****************************************/
6
7 #ifndef __PHOENIX_CHECK_IMPL_H__
8 #define __PHOENIX_CHECK_IMPL_H__
9
10 #include <iostream>
11 #include "phoenix_check.h"
12
13 ///Check two value
14 /** @param testName : name of the current test
15 * @param val : value to be checked
16 * @param reference : reference value
17 * @return true if var == reference, false otherwise
18 */
19 template<typename T>
20 87 bool phoenix_check(const std::string & testName, const T & val, const T & reference){
21 87 bool b(val == reference);
22
2/2
✓ Branch 0 taken 1 times.
✓ Branch 1 taken 26 times.
87 if(!b){
23
2/4
✓ Branch 5 taken 1 times.
✗ Branch 6 not taken.
✓ Branch 8 taken 1 times.
✗ Branch 9 not taken.
23 std::cout << "phoenix_check : " << testName << " => " << phoenix_isOk(b) << std::endl;
24 23 std::cout << "\tval = '"<<val<<"'" << std::endl;
25 23 std::cout << "\treference = '"<<reference<<"'" << std::endl;
26 }
27 87 return b;
28 }
29
30
31 #endif
32