summaryrefslogtreecommitdiff
path: root/test/array_funTest.cc
diff options
context:
space:
mode:
authorTatsuhiro Tsujikawa <tatsuhiro.t@gmail.com>2013-07-03 23:23:22 +0900
committerTatsuhiro Tsujikawa <tatsuhiro.t@gmail.com>2013-07-03 23:23:22 +0900
commit7e6db8d801973bfc62b80f411f14d1d332a1f7aa (patch)
tree9ace3886df397907d113b97ec132e64f6729ea02 /test/array_funTest.cc
parentdf0034f1cd5a3c642fba65f228da7ca0674161b8 (diff)
Use std::unique_ptr instead of array_ptr
Diffstat (limited to 'test/array_funTest.cc')
-rw-r--r--test/array_funTest.cc24
1 files changed, 0 insertions, 24 deletions
diff --git a/test/array_funTest.cc b/test/array_funTest.cc
index 1158d577..ae796c8c 100644
--- a/test/array_funTest.cc
+++ b/test/array_funTest.cc
@@ -11,7 +11,6 @@ class array_funTest:public CppUnit::TestFixture {
CPPUNIT_TEST(testArray_negate);
CPPUNIT_TEST(testArray_and);
CPPUNIT_TEST(testArrayLength);
- CPPUNIT_TEST(testArrayPtr);
CPPUNIT_TEST(testArrayWrapper);
CPPUNIT_TEST_SUITE_END();
@@ -21,7 +20,6 @@ public:
void testArray_negate();
void testArray_and();
void testArrayLength();
- void testArrayPtr();
void testArrayWrapper();
struct X{
@@ -71,15 +69,6 @@ void array_funTest::testArrayLength()
}
namespace {
-// Check operator[] in const context.
-void arrayPtrConst(const array_ptr<struct array_funTest::X>& ax)
-{
- CPPUNIT_ASSERT_EQUAL(100, ax[3].m);
- CPPUNIT_ASSERT_EQUAL(99, ax[2].m);
-}
-} // namespace
-
-namespace {
void arrayPtrCast(struct array_funTest::X* x) {}
} // namespace
@@ -87,19 +76,6 @@ namespace {
void arrayPtrConstCast(const struct array_funTest::X* x) {}
} // namespace
-void array_funTest::testArrayPtr()
-{
- array_ptr<struct X> ax(new struct X[10]);
- ax[3].m = 100;
- ax[2].m = 99;
- CPPUNIT_ASSERT_EQUAL(100, ax[3].m);
- CPPUNIT_ASSERT_EQUAL(99, ax[2].m);
- arrayPtrConst(ax);
-
- arrayPtrCast(ax);
- arrayPtrConstCast(ax);
-}
-
namespace {
void arrayWrapperConst(const array_wrapper<int, 10>& array)
{