From d2f4c5c243367a39f94c240eed3da3649ef4a455 Mon Sep 17 00:00:00 2001 From: Geir Storli Date: Tue, 28 May 2019 08:30:38 +0000 Subject: Rewrite storageserver tests from cppunit to gtest. Also remove a set of tests that have been ignored / disabled for 8 years. These were highly unstable integration tests. System tests should cover such cases instead. --- storageserver/src/tests/testhelper.h | 37 ++---------------------------------- 1 file changed, 2 insertions(+), 35 deletions(-) (limited to 'storageserver/src/tests/testhelper.h') diff --git a/storageserver/src/tests/testhelper.h b/storageserver/src/tests/testhelper.h index 9db4a93041a..7dbaaecdbf4 100644 --- a/storageserver/src/tests/testhelper.h +++ b/storageserver/src/tests/testhelper.h @@ -1,35 +1,10 @@ // Copyright 2017 Yahoo Holdings. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. #pragma once -#include -#include - #include -#include #include - -#define ASSERT_REPLY_COUNT(count, dummylink) \ - { \ - std::ostringstream msgost; \ - if ((dummylink).getNumReplies() != count) { \ - for (uint32_t ijx=0; ijx<(dummylink).getNumReplies(); ++ijx) { \ - msgost << (dummylink).getReply(ijx)->toString(true) << "\n"; \ - } \ - } \ - CPPUNIT_ASSERT_EQUAL_MSG(msgost.str(), size_t(count), \ - (dummylink).getNumReplies()); \ - } -#define ASSERT_COMMAND_COUNT(count, dummylink) \ - { \ - std::ostringstream msgost; \ - if ((dummylink).getNumCommands() != count) { \ - for (uint32_t ijx=0; ijx<(dummylink).getNumCommands(); ++ijx) { \ - msgost << (dummylink).getCommand(ijx)->toString(true) << "\n"; \ - } \ - } \ - CPPUNIT_ASSERT_EQUAL_MSG(msgost.str(), size_t(count), \ - (dummylink).getNumCommands()); \ - } +#include +#include namespace storage { @@ -45,13 +20,5 @@ vdstestlib::DirConfig getStandardConfig(bool storagenode); void addSlobrokConfig(vdstestlib::DirConfig& dc, const mbus::Slobrok& slobrok); -// Class used to print start and end of test. Enable debug when you want to see -// which test creates what output or where we get stuck -struct TestName { - std::string name; - TestName(const std::string& n); - ~TestName(); -}; - } // storage -- cgit v1.2.3