diff --git a/trick_source/sim_services/MemoryManager/test/MM_ref_attributes_unittest.cc b/trick_source/sim_services/MemoryManager/test/MM_ref_attributes_unittest.cc index 5d094ab6..a2c7490f 100644 --- a/trick_source/sim_services/MemoryManager/test/MM_ref_attributes_unittest.cc +++ b/trick_source/sim_services/MemoryManager/test/MM_ref_attributes_unittest.cc @@ -78,6 +78,11 @@ TEST_F(MM_ref_attributes, NormalCases) { ref = memmgr->ref_attributes("udt3.M2"); ASSERT_TRUE(ref != NULL); EXPECT_EQ( &udt3.M2, ref->address); + + ASSERT_TRUE(ref->attr != NULL); + ASSERT_TRUE(ref->attr->units != NULL); + std::cout << "Units of udt3.M2 = " << ref->attr->units << std::endl; + free( ref); std::cout << "Case of: \"udt3.M2[2][3]\"" << std::endl; @@ -90,6 +95,10 @@ TEST_F(MM_ref_attributes, NormalCases) { ref = memmgr->ref_attributes("udt3.M3[1][1][3]"); ASSERT_TRUE(ref != NULL); EXPECT_EQ( &udt3.M3[1][1][3], ref->address); + + ASSERT_TRUE(ref->attr != NULL); + ASSERT_TRUE(ref->attr->units != NULL); + std::cout << "Units of udt3.M3 = " << ref->attr->units << std::endl; free( ref); std::cout << "Case of: \"udt3.C[5]\"" << std::endl; diff --git a/trick_source/sim_services/MemoryManager/test/MM_user_defined_types.hh b/trick_source/sim_services/MemoryManager/test/MM_user_defined_types.hh index ed67e86b..b67384f6 100644 --- a/trick_source/sim_services/MemoryManager/test/MM_user_defined_types.hh +++ b/trick_source/sim_services/MemoryManager/test/MM_user_defined_types.hh @@ -72,7 +72,7 @@ class UDT3 { double Z; int I; double M2[3][4]; /* r */ - double M3[2][3][4]; /* r */ + double M3[2][3][4]; /* d */ char C[10]; UDT2 N; UDT2 NA[2];