diff --git a/gtsam/geometry/tests/testCal3Unified.cpp b/gtsam/geometry/tests/testCal3Unified.cpp index b260415f1..de9a8b739 100644 --- a/gtsam/geometry/tests/testCal3Unified.cpp +++ b/gtsam/geometry/tests/testCal3Unified.cpp @@ -19,6 +19,9 @@ #include #include +#include +#include + using namespace gtsam; GTSAM_CONCEPT_TESTABLE_INST(Cal3Unified) @@ -97,6 +100,19 @@ TEST( Cal3Unified, retract) CHECK(assert_equal(d,K.localCoordinates(actual),1e-9)); } +/* ************************************************************************* */ +TEST( Cal3Unified, DerivedValue) +{ + Values values; + Cal3Unified cal(1, 2, 3, 4, 5, 6, 7, 8, 9, 10); + Key key = 1; + values.insert(key, cal); + + Cal3Unified calafter = values.at(key); + + CHECK(assert_equal(cal,calafter,1e-9)); +} + /* ************************************************************************* */ int main() { TestResult tr; return TestRegistry::runAllTests(tr); } /* ************************************************************************* */