+ return 1; // allways true (we don't want to break the test suite)
+}
+
+
+int TestValidate(int argc, char *argv[])
+{
+ if ( argc == 2 )
+ {
+ // The test is specified a specific filename, use it instead of looping
+ // over all images
+ const std::string input = argv[1];
+ return Validate( input );
+ }
+ else if ( argc > 2 || argc == 2 )
+ {
+ std::cout << " Usage: " << argv[0]
+ << " (no arguments needed)." << std::endl;
+ std::cout << "or Usage: " << argv[0]
+ << " filename.dcm " << std::endl;
+ return 1;
+ }
+ // Try to track the "FIXME" problem for VM
+ gdcm::Global::GetDicts()->GetDefaultPubDict()->Print();
+
+ int i =0;
+ int retVal = 0; //by default this is an error
+ while( gdcmDataImages[i] != 0 )
+ {
+ std::string filename = GDCM_DATA_ROOT;
+ filename += "/"; //doh!
+ filename += gdcmDataImages[i];
+ std::cout << filename << std::endl;
+ if( Validate( filename ) != 0 )
+ {
+ retVal++;
+ }