TP Histogramme.
[GPU.git] / WCudaMSE / Student_Cuda / src / cpp / test / junit / 01_Test_Hello / TestHello.cpp
1 #include "TestHello.h"
2 #include "Device.h"
3
4 /*----------------------------------------------------------------------*\
5 |* Declaration *|
6 \*---------------------------------------------------------------------*/
7
8 /*--------------------------------------*\
9 |* Imported *|
10 \*-------------------------------------*/
11
12 extern bool helloCuda(void);
13 extern bool isAddScalarGPU_Ok(void);
14
15 /*----------------------------------------------------------------------*\
16 |* Implementation *|
17 \*---------------------------------------------------------------------*/
18
19 /*--------------------------------------*\
20 |* Constructor *|
21 \*-------------------------------------*/
22
23 TestHello::TestHello(int deviceId)
24 {
25 this->deviceId=deviceId;
26
27 TEST_ADD(TestHello::testHelloCuda);
28 TEST_ADD(TestHello::testAdd);
29 }
30
31 /*--------------------------------------*\
32 |* Methodes *|
33 \*-------------------------------------*/
34
35 void TestHello::testHelloCuda(void)
36 {
37 TEST_ASSERT(helloCuda() == true);
38 }
39
40 void TestHello::testAdd(void)
41 {
42 TEST_ASSERT(isAddScalarGPU_Ok() == true);
43 }
44
45 /*----------------------------------------------------------------------*\
46 |* End *|
47 \*---------------------------------------------------------------------*/
48