Shih-wei Liao | 5460a1f | 2012-03-16 22:41:16 -0700 | [diff] [blame] | 1 | //===- PathTest.h ---------------------------------------------------------===// |
| 2 | // |
| 3 | // The MCLinker Project |
| 4 | // |
| 5 | // This file is distributed under the University of Illinois Open Source |
| 6 | // License. See LICENSE.TXT for details. |
| 7 | // |
| 8 | //===----------------------------------------------------------------------===// |
| 9 | #ifndef PATH_TEST_H |
| 10 | #define PATH_TEST_H |
| 11 | |
| 12 | #include "mcld/Support/Path.h" |
| 13 | #include <gtest.h> |
| 14 | |
Stephen Hines | 37b74a3 | 2014-11-26 18:48:20 -0800 | [diff] [blame] | 15 | namespace mcldtest { |
Shih-wei Liao | 5460a1f | 2012-03-16 22:41:16 -0700 | [diff] [blame] | 16 | |
| 17 | /** \class PathTest |
| 18 | * \brief a testcase for mcld::Path and its non-member funtions. |
| 19 | * |
Stephen Hines | 551ae4e | 2014-04-24 14:41:24 -0700 | [diff] [blame] | 20 | * \see Path |
Shih-wei Liao | 5460a1f | 2012-03-16 22:41:16 -0700 | [diff] [blame] | 21 | */ |
Stephen Hines | 37b74a3 | 2014-11-26 18:48:20 -0800 | [diff] [blame] | 22 | class PathTest : public ::testing::Test { |
| 23 | public: |
| 24 | // Constructor can do set-up work for all test here. |
| 25 | PathTest(); |
Shih-wei Liao | 5460a1f | 2012-03-16 22:41:16 -0700 | [diff] [blame] | 26 | |
Stephen Hines | 37b74a3 | 2014-11-26 18:48:20 -0800 | [diff] [blame] | 27 | // Destructor can do clean-up work that doesn't throw exceptions here. |
| 28 | virtual ~PathTest(); |
Shih-wei Liao | 5460a1f | 2012-03-16 22:41:16 -0700 | [diff] [blame] | 29 | |
Stephen Hines | 37b74a3 | 2014-11-26 18:48:20 -0800 | [diff] [blame] | 30 | // SetUp() will be called immediately before each test. |
| 31 | virtual void SetUp(); |
Shih-wei Liao | 5460a1f | 2012-03-16 22:41:16 -0700 | [diff] [blame] | 32 | |
Stephen Hines | 37b74a3 | 2014-11-26 18:48:20 -0800 | [diff] [blame] | 33 | // TearDown() will be called immediately after each test. |
| 34 | virtual void TearDown(); |
Shih-wei Liao | 5460a1f | 2012-03-16 22:41:16 -0700 | [diff] [blame] | 35 | |
Stephen Hines | 37b74a3 | 2014-11-26 18:48:20 -0800 | [diff] [blame] | 36 | protected: |
| 37 | mcld::sys::fs::Path* m_pTestee; |
Shih-wei Liao | 5460a1f | 2012-03-16 22:41:16 -0700 | [diff] [blame] | 38 | }; |
| 39 | |
Stephen Hines | 37b74a3 | 2014-11-26 18:48:20 -0800 | [diff] [blame] | 40 | } // namespace of mcldtest |
Shih-wei Liao | 5460a1f | 2012-03-16 22:41:16 -0700 | [diff] [blame] | 41 | |
| 42 | #endif |