]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
Use STUB_RETVAL() to minimize the number of stub lines.
authorAlex Rousskov <rousskov@measurement-factory.com>
Mon, 12 Sep 2011 00:29:56 +0000 (18:29 -0600)
committerAlex Rousskov <rousskov@measurement-factory.com>
Mon, 12 Sep 2011 00:29:56 +0000 (18:29 -0600)
src/tests/stub_MemStore.cc
src/tests/stub_Port.cc

index 67de39a5ecfe1c8b1ead401f67cb1241459e59c5..03bef5cfd01c5098d84a6f9e001f1c14f688c3f2 100644 (file)
@@ -20,57 +20,12 @@ void MemStore::cleanReadable(const sfileno) STUB
 void MemStore::get(String const, STOREGETCLIENT, void *) STUB
 void MemStore::init() STUB
 void MemStore::stat(StoreEntry &) const STUB
-
-int MemStore::callback()
-{
-    STUB
-    return 0;
-}
-
-StoreEntry *MemStore::get(const cache_key *)
-{
-    STUB
-    return NULL;
-}
-
-uint64_t MemStore::maxSize() const
-{
-    STUB
-    return 0;
-}
-
-uint64_t MemStore::minSize() const
-{
-    STUB
-    return 0;
-}
-
-uint64_t MemStore::currentSize() const
-{
-    STUB
-    return 0;
-}
-
-uint64_t MemStore::currentCount() const
-{
-    STUB
-    return 0;
-}
-
-int64_t MemStore::maxObjectSize() const
-{
-    STUB
-    return 0;
-}
-
-StoreSearch *MemStore::search(String const, HttpRequest *)
-{
-    STUB
-    return NULL;
-}
-
-bool MemStore::dereference(StoreEntry &)
-{
-    STUB
-    return false;
-}
+int MemStore::callback() STUB_RETVAL(0)
+StoreEntry *MemStore::get(const cache_key *) STUB_RETVAL(NULL)
+uint64_t MemStore::maxSize() const STUB_RETVAL(0)
+uint64_t MemStore::minSize() const STUB_RETVAL(0)
+uint64_t MemStore::currentSize() const STUB_RETVAL(0)
+uint64_t MemStore::currentCount() const STUB_RETVAL(0)
+int64_t MemStore::maxObjectSize() const STUB_RETVAL(0)
+StoreSearch *MemStore::search(String const, HttpRequest *) STUB_RETVAL(NULL)
+bool MemStore::dereference(StoreEntry &) STUB_RETVAL(false)
index 4ac50e62592d97cd12e644a6e0b616301171a55e..1d7f2f9b3fa3beab3075d2ec3277dea131526a00 100644 (file)
@@ -7,8 +7,4 @@
 const char Ipc::coordinatorAddr[] = "";
 const char Ipc::strandAddrPfx[] = "";
 
-String Ipc::Port::MakeAddr(char const*, int)
-{
-    STUB
-    return "";
-}
+String Ipc::Port::MakeAddr(char const*, int) STUB_RETVAL("")