Tesseract
Motion Planning Environment
|
#include <tesseract_common/macros.h>
#include <gtest/gtest.h>
#include <tesseract_common/clone_cache.h>
Classes | |
class | TestObject |
Object used to test the CloneCache. More... | |
class | TestObjectSupportsUpdate |
class | TestObjectSupportsUpdateFailure |
Functions | |
EXPECT_EQ (clone_cache->getCacheSize(), 3) | |
EXPECT_EQ (original->val_1, clone->val_1) | |
EXPECT_NE (original->val_1, clone->val_1) | |
clone_cache | updateCache () |
for (int i=0;i< 10;i++) | |
clone_cache | setCacheSize (8) |
EXPECT_EQ (clone_cache->getCacheSize(), 8) | |
EXPECT_EQ (original->val_1, updated_clone->val_1) | |
EXPECT_EQ (clone_cache->getCurrentCacheSize(), 0) | |
EXPECT_TRUE (clone_cache->clone()==nullptr) | |
int | main (int argc, char **argv) |
Variables | |
original | val_1 = 1 |
original | val_2 = 2 |
auto | clone_cache = std::make_shared<CloneCache<TestObject>>(original, 3) |
original | revision_ |
auto | clone = clone_cache->clone() |
auto | updated_clone = clone_cache->clone() |
EXPECT_EQ | ( | clone_cache-> | getCacheSize(), |
3 | |||
) |
EXPECT_EQ | ( | clone_cache-> | getCacheSize(), |
8 | |||
) |
EXPECT_EQ | ( | clone_cache-> | getCurrentCacheSize(), |
0 | |||
) |
EXPECT_EQ | ( | original-> | val_1, |
clone-> | val_1 | ||
) |
EXPECT_EQ | ( | original-> | val_1, |
updated_clone-> | val_1 | ||
) |
EXPECT_NE | ( | original-> | val_1, |
clone-> | val_1 | ||
) |
EXPECT_TRUE | ( | clone_cache-> | clone() = =nullptr | ) |
for | ( | ) |
int main | ( | int | argc, |
char ** | argv | ||
) |
clone_cache setCacheSize | ( | 8 | ) |
clone_cache updateCache | ( | ) |
auto clone = clone_cache->clone() |
auto clone_cache = std::make_shared<CloneCache<TestObject>>(original, 3) |
original revision_ |
auto updated_clone = clone_cache->clone() |
original val_1 = 1 |
original val_2 = 2 |