You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by na...@apache.org on 2005/10/06 23:28:26 UTC

svn commit: r306899 - /webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/

Author: nadiramra
Date: Thu Oct  6 14:28:18 2005
New Revision: 306899

URL: http://svn.apache.org/viewcvs?rev=306899&view=rev
Log: (empty)

Modified:
    webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/AttDataHandlerText.cpp
    webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/AttMultiAttachment.cpp
    webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/AttMultiAttachmentFault.cpp
    webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/AttMultiSameAttachment.cpp
    webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/AttPlainText.cpp
    webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/Attachment1Client.cpp
    webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/AxisBenchClient.cpp
    webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/CommonClientTestCode.hpp
    webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/InteropTestRound1Client.cpp
    webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/InteropTestRound1DocClient.cpp
    webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/MultiOutClient.cpp
    webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/XSDElementClient.cpp
    webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/XSDElementNilClient.cpp
    webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/XSD_base64BinaryClient.cpp
    webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/XSD_hexBinaryClient.cpp
    webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/XSD_negativeIntegerClient.cpp

Modified: webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/AttDataHandlerText.cpp
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/AttDataHandlerText.cpp?rev=306899&r1=306898&r2=306899&view=diff
==============================================================================
--- webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/AttDataHandlerText.cpp (original)
+++ webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/AttDataHandlerText.cpp Thu Oct  6 14:28:18 2005
@@ -23,6 +23,7 @@
 #include <fstream>
 #include <string.h>
 #include <signal.h>
+#include "CommonClientTestCode.hpp"
 
 void sig_handler(int);
 
@@ -48,8 +49,10 @@
 			{
 				sprintf(endpoint, "%s", url);
 				DataHandlerService ws(endpoint);
-				ISoapAttachment *att=ws.createSoapAttachment();				
-				char *text="This is a test message for attachment";
+				ISoapAttachment *att=ws.createSoapAttachment();	
+			
+				char *text=stringToAscii("This is a test message for attachment");
+
 				//Adding the content type as text/plain
 				att->addHeader(AXIS_CONTENT_TYPE,"text/plain");
 				xsd__base64Binary b64b1;

Modified: webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/AttMultiAttachment.cpp
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/AttMultiAttachment.cpp?rev=306899&r1=306898&r2=306899&view=diff
==============================================================================
--- webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/AttMultiAttachment.cpp (original)
+++ webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/AttMultiAttachment.cpp Thu Oct  6 14:28:18 2005
@@ -23,6 +23,7 @@
 #include <fstream>
 #include <string.h>
 #include <signal.h>
+#include "CommonClientTestCode.hpp"
 
 void sig_handler(int);
 
@@ -52,8 +53,10 @@
 				ISoapAttachment *att1=ws.createSoapAttachment();
 				ISoapAttachment *att2=ws.createSoapAttachment();
 				ISoapAttachment *att3=ws.createSoapAttachment();
-				char *text="This is a test message for attachment";
-				//Adding the content type as text/plain
+
+				char *text=stringToAscii("This is a test message for attachment");
+
+  			      //Adding the content type as text/plain
 				att->addHeader(AXIS_CONTENT_TYPE,"text/plain");
 				//Adding the content id
 				att2->addHeader(AXIS_CONTENT_ID,"5");
@@ -114,4 +117,5 @@
     cout << "SIGNAL RECEIVED " << sig << endl;
 	exit(1);
 }
+
 

Modified: webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/AttMultiAttachmentFault.cpp
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/AttMultiAttachmentFault.cpp?rev=306899&r1=306898&r2=306899&view=diff
==============================================================================
--- webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/AttMultiAttachmentFault.cpp (original)
+++ webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/AttMultiAttachmentFault.cpp Thu Oct  6 14:28:18 2005
@@ -26,6 +26,7 @@
 #include <fstream>
 #include <string.h>
 #include <signal.h>
+#include "CommonClientTestCode.hpp"
 
 void sig_handler(int);
 
@@ -55,7 +56,9 @@
 				ISoapAttachment *att1=ws.createSoapAttachment();
 				ISoapAttachment *att2=ws.createSoapAttachment();
 				ISoapAttachment *att3=ws.createSoapAttachment();
-				char *text="This is a test message for attachment";
+
+				char *text=stringToAscii("This is a test message for attachment");
+
 				//Adding the content type as text/plain
 				att->addHeader(AXIS_CONTENT_TYPE,"text/plain");
 				att2->addHeader(AXIS_CONTENT_ID,"5");

Modified: webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/AttMultiSameAttachment.cpp
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/AttMultiSameAttachment.cpp?rev=306899&r1=306898&r2=306899&view=diff
==============================================================================
--- webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/AttMultiSameAttachment.cpp (original)
+++ webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/AttMultiSameAttachment.cpp Thu Oct  6 14:28:18 2005
@@ -23,6 +23,7 @@
 #include <fstream>
 #include <string.h>
 #include <signal.h>
+#include "CommonClientTestCode.hpp"
 
 void sig_handler(int);
 
@@ -49,8 +50,10 @@
 				sprintf(endpoint, "%s", url);
 				AttachmentService ws(endpoint);
 				ISoapAttachment *att1=ws.createSoapAttachment();
-				ISoapAttachment *att2=ws.createSoapAttachment();				
-				char *text="This is a test message for attachment";
+				ISoapAttachment *att2=ws.createSoapAttachment();
+				
+				char *text=stringToAscii("This is a test message for attachment");
+
 				//Adding the content type as text/plain
 				att1->addHeader(AXIS_CONTENT_TYPE,"text/plain");
 				att2->addHeader(AXIS_CONTENT_ID,"5");

Modified: webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/AttPlainText.cpp
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/AttPlainText.cpp?rev=306899&r1=306898&r2=306899&view=diff
==============================================================================
--- webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/AttPlainText.cpp (original)
+++ webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/AttPlainText.cpp Thu Oct  6 14:28:18 2005
@@ -25,6 +25,7 @@
 #include <fstream>
 #include <string.h>
 #include <signal.h>
+#include "CommonClientTestCode.hpp"
 
 void sig_handler(int);
 
@@ -50,8 +51,10 @@
 			{
 				sprintf(endpoint, "%s", url);
 				AttachmentBindingImpl ws(endpoint);
-				ISoapAttachment *att=ws.createSoapAttachment();				
-				char *text="This is a test message for attachment";
+				ISoapAttachment *att=ws.createSoapAttachment();	
+
+				char *text=stringToAscii("This is a test message for attachment");
+
 				//Adding the content type as text/plain
 				att->addHeader(AXIS_CONTENT_TYPE,"text/plain");
 				xsd__base64Binary b64b1;

Modified: webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/Attachment1Client.cpp
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/Attachment1Client.cpp?rev=306899&r1=306898&r2=306899&view=diff
==============================================================================
--- webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/Attachment1Client.cpp (original)
+++ webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/Attachment1Client.cpp Thu Oct  6 14:28:18 2005
@@ -17,6 +17,7 @@
 #include <axis/AxisException.hpp>
 #include <ctype.h>
 #include <iostream>
+#include "CommonClientTestCode.hpp"
 
 int main(int argc, char* argv[])
 {
@@ -29,7 +30,8 @@
 		{
 			AttachmentBindingImpl ws(argv[1]);
 
-			char *text="Some attachment text";
+			char *text=stringToAscii("Some attachment text");
+
 			#define NUM_ATTS 6
 			ISoapAttachment *att[NUM_ATTS];
 			xsd__base64Binary b64b[NUM_ATTS];
@@ -101,3 +103,4 @@
 	}
 	return true;
 }
+

Modified: webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/AxisBenchClient.cpp
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/AxisBenchClient.cpp?rev=306899&r1=306898&r2=306899&view=diff
==============================================================================
--- webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/AxisBenchClient.cpp (original)
+++ webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/AxisBenchClient.cpp Thu Oct  6 14:28:18 2005
@@ -90,9 +90,10 @@
     struct tm lt;
     memcpy(&lt, temp, sizeof(struct tm));
 
-      
+    char *letterA_String = stringToAscii("A");  
     buffer = (xsd__unsignedByte*)calloc (1, input->count + 2);
-    strcpy ( (char *)buffer, "A");
+
+    strcpy ( (char *)buffer, letterA_String);  
 
     for ( int i = 0; i < input->count ; i++ ) {
         BenchBasicDataType *type = new BenchBasicDataType();
@@ -136,7 +137,7 @@
 			ll += 10000;
 		}
 
-        strcat ( (char *)buffer, "A");
+        strcat ( (char *)buffer, letterA_String);
     }
 
     int t1,t2;
@@ -204,6 +205,12 @@
 // See XSDTime or XSDTimeNil testcases for full validation of the xsd:time type
 //            strftime(dateTime, 50, "%H:%M:%S", &output->infos.m_Array[i]->TimeType);
 //			  cout << " TimeType " << dateTime << endl;
+
+// Following check for os/400 - the mock server will return ascii char which needs to be converted
+#ifdef __OS400__
+                    if (output->infos.m_Array[i]->ByteType == 0x31) 
+                      output->infos.m_Array[i]->ByteType = '1';
+#endif
 			  cout << " ByteType " << output->infos.m_Array[i]->ByteType << endl;
 			  cout << " DecimalType " << output->infos.m_Array[i]->DecimalType << endl;
 			  cout << " FloatType " << output->infos.m_Array[i]->FloatType << endl;
@@ -214,13 +221,13 @@
 			  cout << " Base64BinaryType " << output->infos.m_Array[i]->Base64BinaryType.__size << endl;
 			  if( output->infos.m_Array[i]->Base64BinaryType.__size > 0)
 			  {
-				  cout << " Base64BinaryType " << output->infos.m_Array[i]->Base64BinaryType.__ptr << endl;
+				  cout << " Base64BinaryType " << asciiToString((char *)output->infos.m_Array[i]->Base64BinaryType.__ptr) << endl;
 			  }
 
 			  cout << " HexBinaryType " << output->infos.m_Array[i]->HexBinary.__size << endl;
 			  if( output->infos.m_Array[i]->HexBinary.__size > 0)
 			  {
-				cout << " HexBinaryType " << output->infos.m_Array[i]->HexBinary.__ptr << endl;
+				cout << " HexBinaryType " << asciiToString((char *)output->infos.m_Array[i]->HexBinary.__ptr) << endl;
 			  }
 		  }
 		  returnValue=0;
@@ -372,4 +379,3 @@
         cout.rdbuf( output_file.rdbuf() );
     }
 }
-

Modified: webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/CommonClientTestCode.hpp
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/CommonClientTestCode.hpp?rev=306899&r1=306898&r2=306899&view=diff
==============================================================================
--- webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/CommonClientTestCode.hpp (original)
+++ webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/CommonClientTestCode.hpp Thu Oct  6 14:28:18 2005
@@ -1,7 +1,7 @@
-#ifdef WIN32
-	#if defined(_MSC_VER) && (_MSC_VER < 1300)
-	// Bug in MS Visual C++ 6.0. Fixed in Visual C++ .Net version.
-	// Cannot print an __int64 number with cout without this overloading
+#ifdef WIN32
+	#if defined(_MSC_VER) && (_MSC_VER < 1300)
+	// Bug in MS Visual C++ 6.0. Fixed in Visual C++ .Net version.
+	// Cannot print an __int64 number with cout without this overloading
 		std::ostream& operator << (std::ostream& os, __int64 i)
 		{
 			char buf[32];
@@ -23,5 +23,93 @@
 
 			return os;
 		}
-	#endif
-#endif
+	#endif
+#endif
+
+// ==========================================================
+// Following code is to take care of ebcdic/ascii issues.
+// Some test cases relating to hex and binary and attachement
+// send text strings. In order for these test cases to 
+// pass we need to ensure that the data is in ascii. 
+// In addition, if we are going to print out the data to cout,
+// then we need to convert to ebcdic. For ascii-based systems,
+// the macros used to do the conversions are identity macros. 
+// ==========================================================
+#ifdef __OS400__
+
+/* conversion table generated by ebcdic 37 -> ascii 819 */
+const char EBCDICtoASCII[256] = {
+/* 0    1    2    3    4    5    6    7    8    9    A    B    C    D    E    F */
+   0,   1,   2,   3, 156,   9, 134, 127, 151, 141, 142,  11,  12,  13,  14,  15,    
+  16,  17,  18,  19, 157, 133,   8, 135,  24,  25, 146, 143,  28,  29,  30,  31,    
+ 128, 129, 130, 131, 132,  10,  23,  27, 136, 137, 138, 139, 140,   5,   6,   7,    
+ 144, 145,  22, 147, 148, 149, 150,   4, 152, 153, 154, 155,  20,  21, 158,  26,    
+  32, 160, 226, 228, 224, 225, 227, 229, 231, 241, 162,  46,  60,  40,  43, 124,    
+  38, 233, 234, 235, 232, 237, 238, 239, 236, 223,  33,  36,  42,  41,  59, 172,    
+  45,  47, 194, 196, 192, 193, 195, 197, 199, 209, 166,  44,  37,  95,  62,  63,    
+  248, 201, 202, 203, 200, 205, 206, 207, 204,  96,  58,  35,  64,  39,  61,  34,   
+  216,  97,  98,  99, 100, 101, 102, 103, 104, 105, 171, 187, 240, 253, 254, 177,   
+  176, 106, 107, 108, 109, 110, 111, 112, 113, 114, 170, 186, 230, 184, 198, 164,   
+  181, 126, 115, 116, 117, 118, 119, 120, 121, 122, 161, 191, 208, 221, 222, 174,   
+   94, 163, 165, 183, 169, 167, 182, 188, 189, 190,  91,  93, 175, 168, 180, 215,   
+  123,  65,  66,  67,  68,  69,  70,  71,  72,  73, 173, 244, 246, 242, 243, 245,   
+  125,  74,  75,  76,  77,  78,  79,  80,  81,  82, 185, 251, 252, 249, 250, 255,   
+   92, 247,  83,  84,  85,  86,  87,  88,  89,  90, 178, 212, 214, 210, 211, 213,   
+   48,  49,  50,  51,  52,  53,  54,  55,  56,  57, 179, 219, 220, 217, 218, 159
+};
+ 
+/* conversion table generated by ascii 819 -> ebcdic 37 */
+const char ASCIItoEBCDIC[256] = {
+/* 0    1    2    3    4    5    6    7    8    9    A    B    C    D    E    F */
+   0,   1,   2,   3,  55,  45,  46,  47,  22,   5,  37,  11,  12,  13,  14,  15,      
+  16,  17,  18,  19,  60,  61,  50,  38,  24,  25,  63,  39,  28,  29,  30,  31,
+  64,  90, 127, 123,  91, 108,  80, 125,  77,  93,  92,  78, 107,  96,  75,  97,
+ 240, 241, 242, 243, 244, 245, 246, 247, 248, 249, 122,  94,  76, 126, 110, 111,
+ 124, 193, 194, 195, 196, 197, 198, 199, 200, 201, 209, 210, 211, 212, 213, 214,
+ 215, 216, 217, 226, 227, 228, 229, 230, 231, 232, 233, 186, 224, 187, 176, 109,      
+ 121, 129, 130, 131, 132, 133, 134, 135, 136, 137, 145, 146, 147, 148, 149, 150,
+ 151, 152, 153, 162, 163, 164, 165, 166, 167, 168, 169, 192,  79, 208, 161,   7,
+  32,  33,  34,  35,  36,  21,   6,  23,  40,  41,  42,  43,  44,   9,  10,  27,      
+  48,  49,  26,  51,  52,  53,  54,   8,  56,  57,  58,  59,   4,  20,  62, 255,      
+  65, 170,  74, 177, 159, 178, 106, 181, 189, 180, 154, 138,  95, 202, 175, 188,      
+ 144, 143, 234, 250, 190, 160, 182, 179, 157, 218, 155, 139, 183, 184, 185, 171,      
+ 100, 101,  98, 102,  99, 103, 158, 104, 116, 113, 114, 115, 120, 117, 118, 119,      
+ 172, 105, 237, 238, 235, 239, 236, 191, 128, 253, 254, 251, 252, 173, 174,  89,      
+  68,  69,  66,  70,  67,  71, 156,  72,  84,  81,  82,  83,  88,  85,  86,  87,      
+ 140,  73, 205, 206, 203, 207, 204, 225, 112, 221, 222, 219, 220, 141, 142, 223   
+};
+
+char* stringToAscii( char *string )
+{
+   char* pch = string;
+   if( string == NULL ) return NULL;
+ 
+   /* while not EOL... */
+   while( *pch != (char)0 )
+   {
+         *pch = EBCDICtoASCII[*pch];
+         pch++;
+   }
+   return string;
+}
+
+char* asciiToString( char *string )
+{
+   char* pch = string;
+   if( string == NULL ) return NULL;
+ 
+   /* while not EOL... */
+   while( *pch != (char)0 )
+   {
+         *pch = ASCIItoEBCDIC[*pch];
+         pch++;
+   }
+   return string;
+}
+
+#else
+
+#define asciiToString( x ) ( x )
+#define stringToAscii( x ) ( x )
+
+#endif

Modified: webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/InteropTestRound1Client.cpp
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/InteropTestRound1Client.cpp?rev=306899&r1=306898&r2=306899&view=diff
==============================================================================
--- webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/InteropTestRound1Client.cpp (original)
+++ webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/InteropTestRound1Client.cpp Thu Oct  6 14:28:18 2005
@@ -19,6 +19,7 @@
 using namespace std;
 
 #include "InteropTestPortType.hpp" 
+#include "CommonClientTestCode.hpp"
 
 #define ARRAYSIZE 2
 
@@ -166,7 +167,7 @@
 	printf("successful\n");
 	//testing echo base 64 binary
 
-	const char* bstr = "some string that is sent encoded to either base64Binary or hexBinary";
+	const char* bstr = stringToAscii("some string that is sent encoded to either base64Binary or hexBinary");
 
 	printf("invoking echoBase64...\n");
 	xsd__base64Binary bb;
@@ -176,7 +177,7 @@
 	if (bb.__size == ws.echoBase64(bb).__size)
 	{
 		printf("successful\n");
-		printf("Returned String :\n%s\n", bb.__ptr);
+		printf("Returned String :\n%s\n", asciiToString((char *)bb.__ptr));
 	}
 	else
 		printf("failed\n");
@@ -188,7 +189,9 @@
    
 	printf("invoking echoDate...\n");
 	ws.setTransportProperty("SOAPAction" , "InteropBase#echoDate");
-	if (memcmp(&ws.echoDate(time), &time, sizeof(tm)) == 0)
+      
+      xsd__dateTime ed_temp = ws.echoDate(time);
+	if (memcmp(&ed_temp, &time, sizeof(tm)) == 0)
 		printf("successful\n");
 	else
 		printf("failed\n");
@@ -202,7 +205,7 @@
 	if (hb.__size == ws.echoHexBinary(hb).__size)
 	{
 		printf("successful\n");
-		printf("Returned String :\n%s\n", hb.__ptr);
+		printf("Returned String :\n%s\n", asciiToString((char *)hb.__ptr));
 	}
 	else
 		printf("failed\n");

Modified: webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/InteropTestRound1DocClient.cpp
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/InteropTestRound1DocClient.cpp?rev=306899&r1=306898&r2=306899&view=diff
==============================================================================
--- webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/InteropTestRound1DocClient.cpp (original)
+++ webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/InteropTestRound1DocClient.cpp Thu Oct  6 14:28:18 2005
@@ -19,6 +19,7 @@
 using namespace std;
 
 #include "InteropTestPortTypeDoc.hpp" 
+#include "CommonClientTestCode.hpp"
 
 #define ARRAYSIZE 2
 
@@ -153,7 +154,7 @@
 	printf("successful\n");
 	//testing echo base 64 binary
 
-	const char* bstr = "some string that is sent encoded to either base64Binary or hexBinary";
+	const char* bstr = stringToAscii("some string that is sent encoded to either base64Binary or hexBinary");
 
 	printf("invoking echoBase64...\n");
 	xsd__base64Binary bb;
@@ -163,7 +164,7 @@
 	if (bb.__size == ws.echoBase64(bb).__size)
 	{
 		printf("successful\n");
-		printf("Returned String :\n%s\n", bb.__ptr);
+		printf("Returned String :\n%s\n", asciiToString((char *)bb.__ptr));
 	}
 	else
 		printf("failed\n");
@@ -175,7 +176,9 @@
    
 	printf("invoking echoDate...\n");
 	ws.setTransportProperty("SOAPAction" , "InteropBaseDoc#echoDate");
-	if (memcmp(ws.echoDate(time), time, sizeof(tm)) == 0)
+
+      xsd__dateTime ed_temp = ws.echoDate(time);
+	if (memcmp(&ed_temp, &time, sizeof(tm)) == 0)
 		printf("successful\n");
 	else
 		printf("failed\n");
@@ -189,7 +192,7 @@
 	if (hb.__size == ws.echoHexBinary(hb).__size)
 	{
 		printf("successful\n");
-		printf("Returned String :\n%s\n", hb.__ptr);
+		printf("Returned String :\n%s\n", asciiToString((char *)hb.__ptr));
 	}
 	else
 		printf("failed\n");

Modified: webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/MultiOutClient.cpp
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/MultiOutClient.cpp?rev=306899&r1=306898&r2=306899&view=diff
==============================================================================
--- webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/MultiOutClient.cpp (original)
+++ webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/MultiOutClient.cpp Thu Oct  6 14:28:18 2005
@@ -69,6 +69,10 @@
 			cout << OutValue6 << endl;
 			cout << OutValue7 << endl;
 			cout << sBool << endl;
+#ifdef __OS400__
+                  if (OutValue9 == 0x41) // Ascii 'A'
+                     OutValue9 = 'A';    // Set to ebcdic A
+#endif
 			cout << OutValue9 << endl;
 			bSuccess = true;
 		}
@@ -105,4 +109,3 @@
 	cout<< "---------------------- TEST COMPLETE -----------------------------"<< endl;
 	return 0;
 }
-

Modified: webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/XSDElementClient.cpp
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/XSDElementClient.cpp?rev=306899&r1=306898&r2=306899&view=diff
==============================================================================
--- webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/XSDElementClient.cpp (original)
+++ webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/XSDElementClient.cpp Thu Oct  6 14:28:18 2005
@@ -13,7 +13,7 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-
+ 
 /*
  * Supported types are
   1 <element name="getBoolean">
@@ -77,7 +77,8 @@
 	xsd__hexBinary hexTest;
 
 	//xsd__unsignedByte* testUB = (xsd__unsignedByte*)"never odd or even";
-	xsd__unsignedByte* testUB = (xsd__unsignedByte*)"<test><xml>some dod&y string</xml></test>";
+
+	xsd__unsignedByte* testUB = (xsd__unsignedByte*)stringToAscii("<test><xml>some dod&y string</xml></test>");
 
 	b64Test.__ptr=testUB;
 	b64Test.__size=41;
@@ -196,14 +197,14 @@
 		cout << "base64Binary size=" << b64Result.__size << endl;
 		if( b64Result.__size > 0)
 		{
-			cout << "base64Binary data=" << b64Result.__ptr << endl;
+			cout << "base64Binary data=" << asciiToString((char *)b64Result.__ptr) << endl;
 		}
 
 		hexResult = ws->setGetHexBinary(hexTest);
 		cout << "hexBinary size=" << hexResult.__size << endl;
 		if( hexResult.__size > 0)
 		{
-			cout << "hexBinary data=" << hexResult.__ptr << endl;
+			cout << "hexBinary data=" << asciiToString((char *)hexResult.__ptr) << endl;
 		}
 
 		bSuccess = true;
@@ -244,4 +245,5 @@
 	
 	return 0;
 }
+
 

Modified: webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/XSDElementNilClient.cpp
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/XSDElementNilClient.cpp?rev=306899&r1=306898&r2=306899&view=diff
==============================================================================
--- webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/XSDElementNilClient.cpp (original)
+++ webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/XSDElementNilClient.cpp Thu Oct  6 14:28:18 2005
@@ -13,7 +13,7 @@
 // See the License for the specific language governing permissions and
 // limitations under the License.
 
-
+ 
 /*
  * Supported types are
   1 <element name="getBoolean">
@@ -98,7 +98,9 @@
 	xsd__hexBinary hexTest;
 
 	//xsd__unsignedByte* testUB = (xsd__unsignedByte*)"never odd or even";
-	xsd__unsignedByte* testUB = (xsd__unsignedByte*)"<test><xml>some dod&y string</xml></test>";
+
+	xsd__unsignedByte* testUB = (xsd__unsignedByte*)stringToAscii("<test><xml>some dod&y string</xml></test>");
+
 
 	b64Test.__ptr=testUB;
 	b64Test.__size=41;
@@ -276,7 +278,7 @@
 		cout << "base64Binary size=" << b64Result->__size << endl;
 		if( b64Result->__size > 0)
 		{
-			cout << "base64Binary data=" << b64Result->__ptr << endl;
+			cout << "base64Binary data=" << asciiToString((char *)b64Result->__ptr) << endl;
 		}
 		b64Result = ws->setGetBase64BinaryType(NULL);
 		if(b64Result)
@@ -288,7 +290,7 @@
 		cout << "hexBinary size=" << hexResult->__size << endl;
 		if( hexResult->__size > 0)
 		{
-			cout << "hexBinary data=" << hexResult->__ptr << endl;
+			cout << "hexBinary data=" << asciiToString((char *)hexResult->__ptr) << endl;
 		}
 		hexResult = ws->setGetHexBinary(&hexTest);
 		if(hexResult)
@@ -334,4 +336,3 @@
 	
 	return 0;
 }
-

Modified: webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/XSD_base64BinaryClient.cpp
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/XSD_base64BinaryClient.cpp?rev=306899&r1=306898&r2=306899&view=diff
==============================================================================
--- webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/XSD_base64BinaryClient.cpp (original)
+++ webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/XSD_base64BinaryClient.cpp Thu Oct  6 14:28:18 2005
@@ -18,6 +18,7 @@
 #include <axis/AxisException.hpp>
 #include <ctype.h>
 #include <iostream>
+#include "CommonClientTestCode.hpp"
 
 
 int main(int argc, char* argv[])
@@ -36,7 +37,9 @@
 		XSD_base64Binary* ws = new XSD_base64Binary(endpoint);
 
         xsd__base64Binary input;
-        xsd__unsignedByte* testUB = (xsd__unsignedByte*)"<test><xml>some dod&y string</xml></test>";
+
+        xsd__unsignedByte* testUB = (xsd__unsignedByte*)stringToAscii("<test><xml>some dod&y string</xml></test>");
+
         input.__ptr=testUB;
         input.__size=41;
 
@@ -44,7 +47,7 @@
 	    xsd__base64Binary result = ws->asNonNillableElement(input);
 		cout << "non-nillable element" << endl;
         cout << " size=" << result.__size << endl;
-        cout << " data=" << result.__ptr << endl;
+        cout << " data=" << asciiToString((char *)result.__ptr) << endl;
 
 		// Test nillable element, with a value
 		xsd__base64Binary* nillableInput = new xsd__base64Binary();
@@ -54,7 +57,7 @@
 		{
 			cout << "nillable element" << endl;
             cout << " size=" << nillableResult->__size << endl;
-            cout << " data=" << nillableResult->__ptr << endl;
+            cout << " data=" << asciiToString((char *)nillableResult->__ptr) << endl;
             delete nillableResult;
 		}
 		else
@@ -69,7 +72,7 @@
 		{
 			cout << "nillable element=" << endl;
             cout << " size=" << nillableResult->__size << endl;
-            cout << " data=" << nillableResult->__ptr << endl;
+            cout << " data=" << asciiToString((char *)nillableResult->__ptr) << endl;
 			delete nillableResult;
 		}
 		else
@@ -83,7 +86,7 @@
 		RequiredAttributeElement* requiredAttributeResult = ws->asRequiredAttribute(&requiredAttributeInput);
 		cout << "required attribute" << endl;
         cout << " size=" << requiredAttributeResult->getrequiredAttribute().__size << endl;
-        cout << " data=" << requiredAttributeResult->getrequiredAttribute().__ptr << endl;
+        cout << " data=" << asciiToString((char *)requiredAttributeResult->getrequiredAttribute().__ptr) << endl;
 		delete requiredAttributeResult;
 
 /* Optional Attributes currently unsupported by WSDL2Ws
@@ -136,7 +139,7 @@
 		{
 			cout << " element[" << index << "]" << endl;
             cout << "  size=" << arrayResult.m_Array[index]->__size << endl;
-            cout << "  data=" << arrayResult.m_Array[index]->__ptr << endl;
+            cout << "  data=" << asciiToString((char *)arrayResult.m_Array[index]->__ptr) << endl;
 			delete arrayResult.m_Array[index];
 		}
         delete [] array;
@@ -149,7 +152,7 @@
 		SimpleComplexType* complexTypeResult = ws->asComplexType(&complexTypeInput);
 		cout << "within complex type" << endl;
         cout << " size=" << complexTypeResult->getcomplexTypeElement().__size << endl;
-        cout << " data=" << complexTypeResult->getcomplexTypeElement().__ptr << endl;
+        cout << " data=" << asciiToString((char *)complexTypeResult->getcomplexTypeElement().__ptr) << endl;
 		delete complexTypeResult;
 
 		// Tests now complete
@@ -173,3 +176,4 @@
 	
 	return 0;
 }
+

Modified: webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/XSD_hexBinaryClient.cpp
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/XSD_hexBinaryClient.cpp?rev=306899&r1=306898&r2=306899&view=diff
==============================================================================
--- webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/XSD_hexBinaryClient.cpp (original)
+++ webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/XSD_hexBinaryClient.cpp Thu Oct  6 14:28:18 2005
@@ -18,6 +18,7 @@
 #include <axis/AxisException.hpp>
 #include <ctype.h>
 #include <iostream>
+#include "CommonClientTestCode.hpp"
 
 
 int main(int argc, char* argv[])
@@ -34,7 +35,9 @@
         XSD_hexBinary* ws = new XSD_hexBinary(endpoint);
 
         xsd__hexBinary input;
-        xsd__unsignedByte* testUB = (xsd__unsignedByte*)"<test><xml>some dod&y string</xml></test>";
+
+        xsd__unsignedByte* testUB = (xsd__unsignedByte*)stringToAscii("<test><xml>some dod&y string</xml></test>");
+
         input.__ptr=testUB;
         input.__size=41;
 
@@ -42,7 +45,7 @@
         xsd__hexBinary result = ws->asNonNillableElement(input);
         cout << "non-nillable element" << endl;
         cout << " size=" << result.__size << endl;
-        cout << " data=" << result.__ptr << endl;
+        cout << " data=" << asciiToString((char *)result.__ptr) << endl;
 
         // Test nillable element, with a value
         xsd__hexBinary* nillableInput = new xsd__hexBinary();
@@ -52,7 +55,7 @@
         {
             cout << "nillable element" << endl;
             cout << " size=" << nillableResult->__size << endl;
-            cout << " data=" << nillableResult->__ptr << endl;
+            cout << " data=" << asciiToString((char *)nillableResult->__ptr) << endl;
             delete nillableResult;
         }
         else
@@ -67,7 +70,7 @@
         {
             cout << "nillable element" << endl;
             cout << " size=" << nillableResult->__size << endl;
-            cout << " data=" << nillableResult->__ptr << endl;
+            cout << " data=" << asciiToString((char *)nillableResult->__ptr) << endl;
             delete nillableResult;
         }
         else
@@ -81,7 +84,7 @@
         RequiredAttributeElement* requiredAttributeResult = ws->asRequiredAttribute(&requiredAttributeInput);
         cout << "required attribute" << endl;
         cout << " size=" << requiredAttributeResult->getrequiredAttribute().__size << endl;
-        cout << " data=" << requiredAttributeResult->getrequiredAttribute().__ptr << endl;
+        cout << " data=" << asciiToString((char *)requiredAttributeResult->getrequiredAttribute().__ptr) << endl;
         delete requiredAttributeResult;
 
 /* Optional Attributes currently unsupported by WSDL2Ws
@@ -94,7 +97,7 @@
         {
             cout << "optional attribute, with data" << endl;
             cout << " size=" << optionalAttributeResult->getoptionalAttribute()->__size << endl;
-            cout << " data=" << optionalAttributeResult->getoptionalAttribute()->__ptr << endl;
+            cout << " data=" << asciiToString((char *)optionalAttributeResult->getoptionalAttribute()->__ptr) << endl;
         }
         else
         {
@@ -134,7 +137,7 @@
         {
             cout << " element[" << index << "]" << endl;
             cout << "  size=" << arrayResult.m_Array[index]->__size << endl;
-            cout << "  data=" << arrayResult.m_Array[index]->__ptr << endl;
+            cout << "  data=" << asciiToString((char *)arrayResult.m_Array[index]->__ptr) << endl;
             delete arrayResult.m_Array[index];
         }
         delete [] array;
@@ -147,7 +150,7 @@
         SimpleComplexType* complexTypeResult = ws->asComplexType(&complexTypeInput);
         cout << "within complex type" << endl;
         cout << " size=" << complexTypeResult->getcomplexTypeElement().__size << endl;
-        cout << " data=" << complexTypeResult->getcomplexTypeElement().__ptr << endl;
+        cout << " data=" << asciiToString((char *)complexTypeResult->getcomplexTypeElement().__ptr) << endl;
         delete complexTypeResult;
 
         // Tests now complete

Modified: webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/XSD_negativeIntegerClient.cpp
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/XSD_negativeIntegerClient.cpp?rev=306899&r1=306898&r2=306899&view=diff
==============================================================================
--- webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/XSD_negativeIntegerClient.cpp (original)
+++ webservices/axis/trunk/c/tests/auto_build/testcases/client/cpp/XSD_negativeIntegerClient.cpp Thu Oct  6 14:28:18 2005
@@ -35,7 +35,11 @@
         sprintf(endpoint, "%s", url);
         XSD_negativeInteger* ws = new XSD_negativeInteger(endpoint);
 
+#ifdef __OS400__
+        xsd__negativeInteger result = ws->asNonNillableElement((xsd__negativeInteger)-9223372036854775808LL);
+#else
         xsd__negativeInteger result = ws->asNonNillableElement((xsd__negativeInteger)-9223372036854775808);
+#endif
         cout << "non-nillable element=" << result << endl;
         result = ws->asNonNillableElement((xsd__negativeInteger)-1);
         cout << "non-nillable element=" << result << endl;