Skip to content

Commit

Permalink
ENH: Query class name rather than subclass in test macro
Browse files Browse the repository at this point in the history
  • Loading branch information
tbirdso committed Dec 28, 2021
1 parent 7408df4 commit 441fbd0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Modules/Core/TestKernel/include/itkTestingMacros.h
Original file line number Diff line number Diff line change
Expand Up @@ -80,9 +80,9 @@ namespace itk
#else // not GCC
#define ITK_EXERCISE_BASIC_OBJECT_METHODS(object, ClassName, SuperclassName) \
object->Print(std::cout); \
std::cout << "Name of Class = " << object->GetNameOfClass() << std::endl; \
std::cout << "Name of Class = " << object->Self::GetNameOfClass() << std::endl; \
std::cout << "Name of Superclass = " << object->Superclass::GetNameOfClass() << std::endl; \
if (!std::strcmp(object->GetNameOfClass(), #ClassName)) \
if (!std::strcmp(object->Self::GetNameOfClass(), #ClassName)) \
{ \
std::cout << "Class name is correct" << std::endl; \
} \
Expand Down

0 comments on commit 441fbd0

Please sign in to comment.