22 #include <boost/assign/std/list.hpp> 26 using namespace gtsam;
46 if(
sizeof(
Key) == 8) {
48 Key key = 0x7841000000000005;
57 }
else if(
sizeof(
Key) == 4) {
74 EXPECT(LabeledSymbol::TypeTest(
'c')(key));
75 EXPECT(!LabeledSymbol::TypeTest(
'd')(key));
76 EXPECT(LabeledSymbol::LabelTest(
'A')(key));
77 EXPECT(!LabeledSymbol::LabelTest(
'D')(key));
78 EXPECT(LabeledSymbol::TypeLabelTest(
'c',
'A')(key));
79 EXPECT(!LabeledSymbol::TypeLabelTest(
'c',
'D')(key));
94 EXPECT(
"special" == ss2.str());
99 EXPECT(
"cA3" == ss3.str());
Provides additional testing facilities for common data structures.
Concept check for values that can be used in unit tests.
static int runAllTests(TestResult &result)
TEST(LabeledSymbol, KeyLabeledSymbolConversion)
#define EXPECT(condition)
string labeledSymbolMyFormatter(Key key)
Key symbol(unsigned char c, std::uint64_t j)
bool assert_equal(const Matrix &expected, const Matrix &actual, double tol)
#define EXPECT_LONGS_EQUAL(expected, actual)
static const gtsam::KeyFormatter MultiRobotKeyFormatter
std::uint64_t Key
Integer nonlinear key type.