TsHexUtils.h
Go to the documentation of this file.
1 /* Copyright (C) 2008 National Institute For Space Research (INPE) - Brazil.
2 
3  This file is part of the TerraLib - a Framework for building GIS enabled applications.
4 
5  TerraLib is free software: you can redistribute it and/or modify
6  it under the terms of the GNU Lesser General Public License as published by
7  the Free Software Foundation, either version 3 of the License,
8  or (at your option) any later version.
9 
10  TerraLib is distributed in the hope that it will be useful,
11  but WITHOUT ANY WARRANTY; without even the implied warranty of
12  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13  GNU Lesser General Public License for more details.
14 
15  You should have received a copy of the GNU Lesser General Public License
16  along with TerraLib. See COPYING. If not, write to
17  TerraLib Team at <terralib-team@terralib.org>.
18  */
19 
20 /*!
21  \file TsHexUtils.h
22 
23  \brief Test suite for Hex utils.
24  */
25 
26 #ifndef __TERRALIB_UNITTEST_COMMON_INTERNAL_HEXUTILS_H
27 #define __TERRALIB_UNITTEST_COMMON_INTERNAL_HEXUTILS_H
28 
29 // cppUnit
30 #include <cppunit/extensions/HelperMacros.h>
31 
32 /*!
33  \class TsHexUtils
34 
35  \brief Test suite for hex utils.
36  */
37 class TsHexUtils : public CPPUNIT_NS::TestFixture
38 {
39 // It registers this class as a Test Suit
41 
42 // It registers the class methods as Test Cases belonging to the suit
46 
50 
57 
59 
60  public:
61 
62 // It sets up context before running the test.
63  void setUp();
64 
65 // It cleann up after the test run.
66  void tearDown();
67 
68  protected:
69 
70 // Test Cases:
71 
72  /*! \brief Test Case: Get Decimal from Hex (no case sensitive). */
74 
75  /*! \brief Test Case: Get Decimal from Hex (Upper case). */
77 
78  /*! \brief Test Case: Get Decimal from Hex (Lower case). */
80 
81  /*! \brief Test Case: It Converts char to Hex. */
82  void tcChar2Hex();
83  /*! \brief Test Case: It Converts Hex to Char. */
84  void tcHex2Char();
85  /*! \brief Test Case: It Converts Hex to Char. */
86  void tcHex2Char2();
87  /*! \brief Test Case: It Converts Hex to Binary. */
88  void tcHex2Binary_1();
89  /*! \brief Test Case: It Converts Hex to Binary. */
90  void tcHex2Binary_2();
91  /*! \brief Test Case: It Converts Hex to Binary. */
92  void tcHex2Binary_3();
93  /*! \brief Test Case: It Converts Hex to Binary. */
94  void tcHex2Binary2();
95  /*! \brief Test Case: It Converts Binary to Hex */
96  void tcBinary2Hex2_1();
97  /*! \brief Test Case: It Converts Binary to Hex. */
98  void tcBinary2Hex_size();
99 };
100 
101 #endif // __TERRALIB_UNITTEST_COMMON_INTERNAL_HEXUTILS_H
102 
void tcHex2Binary_3()
Test Case: It Converts Hex to Binary.
Definition: TsHexUtils.cpp:432
void tcGetDecimalFromHexLCase()
Test Case: Get Decimal from Hex (Lower case).
Definition: TsHexUtils.cpp:175
void setUp()
Definition: TsHexUtils.cpp:48
CPPUNIT_TEST_SUITE_END()
void tcHex2Binary_2()
Test Case: It Converts Hex to Binary.
Definition: TsHexUtils.cpp:407
void tcGetDecimalFromHexUCase()
Test Case: Get Decimal from Hex (Upper case).
Definition: TsHexUtils.cpp:145
void tcBinary2Hex2_1()
Test Case: It Converts Binary to Hex.
Definition: TsHexUtils.cpp:467
Test suite for hex utils.
Definition: TsHexUtils.h:37
void tcGetDecimalFromHexNotCS()
Test Case: Get Decimal from Hex (no case sensitive).
Definition: TsHexUtils.cpp:94
void tcBinary2Hex_size()
Test Case: It Converts Binary to Hex.
Definition: TsHexUtils.cpp:487
CPPUNIT_TEST(tcHex2Char)
void tearDown()
Definition: TsHexUtils.cpp:83
void tcHex2Char2()
Test Case: It Converts Hex to Char.
Definition: TsHexUtils.cpp:315
void tcHex2Binary_1()
Test Case: It Converts Hex to Binary.
Definition: TsHexUtils.cpp:391
void tcChar2Hex()
Test Case: It Converts char to Hex.
Definition: TsHexUtils.cpp:202
void tcHex2Char()
Test Case: It Converts Hex to Char.
Definition: TsHexUtils.cpp:232
CPPUNIT_TEST_SUITE(TsHexUtils)
void tcHex2Binary2()
Test Case: It Converts Hex to Binary.
Definition: TsHexUtils.cpp:450