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 ja...@apache.org on 2005/02/26 13:09:36 UTC

cvs commit: ws-axis/c/tests/auto_build/testcases/client/cpp IHeaderBlockTest3Client.cpp

jamejose    2005/02/26 04:09:36

  Modified:    c/tests/auto_build/testcases/client/cpp
                        IHeaderBlockTest3Client.cpp
  Log:
  
  
  Revision  Changes    Path
  1.3       +12 -32    ws-axis/c/tests/auto_build/testcases/client/cpp/IHeaderBlockTest3Client.cpp
  
  Index: IHeaderBlockTest3Client.cpp
  ===================================================================
  RCS file: /home/cvs/ws-axis/c/tests/auto_build/testcases/client/cpp/IHeaderBlockTest3Client.cpp,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- IHeaderBlockTest3Client.cpp	18 Feb 2005 13:17:31 -0000	1.2
  +++ IHeaderBlockTest3Client.cpp	26 Feb 2005 12:09:36 -0000	1.3
  @@ -29,42 +29,22 @@
   		const AxisChar *prefix="np";
   		const AxisChar *uri="http://ws.apache.org/";
   		IHeaderBlock *phb = ws.createSOAPHeaderBlock("TestHeader","http://ws.apache.org/");
  -		INamespace *Insp1=phb->createNamespaceDecl(prefix,uri);
  -		/*Adding same namespace declaration*/
  -		INamespace *Insp1a=phb->createNamespaceDecl(prefix,uri);
  -		/*Passing NULL as argument */
  -		INamespace *Insp1b=phb->createNamespaceDecl(NULL,NULL);
  -        if(Insp1b==NULL)
  -			cout << "Null returned for NULL arguments in createNamespaceDecl"<<endl;
  +		INamespace *Insp1=phb->createNamespaceDecl(prefix,uri);			
   		INamespace *Insp2=phb->createNamespaceDecl("np1","http://axis.apache.org/");
   		const AxisChar *temp="apache";
  -		const AxisChar *localname="name";
  -		/*Testing the behaviour with NULL values */
  -		IAttribute *attr1=phb->createAttribute(NULL,NULL,NULL,NULL);
  -        IAttribute *attr2=phb->createAttribute(NULL,NULL,NULL);
  -		if(attr1==NULL && attr2==NULL)
  -			cout << "Null returned for NULL arguments in createAttribute"<<endl;
  -		IAttribute *Iattr1=phb->createAttribute(localname,prefix,temp);
  -		/*Attributes cannot have the same name  */
  -		IAttribute *Iattr1a=phb->createAttribute(localname,prefix,temp);
  -		IAttribute *Iattr2=phb->createAttribute(localname,"np1","","Axis");
  -		/*Attributes cannot have the same name*/
  -		IAttribute *Iattr2a=phb->createAttribute(localname,"np1","","Axis");
  -		/*Attributes cannot have the same name
  -		  Here prefix 'ns2' and 'np' are having same URI value.
  -		  So ns2:Name and np:Name can't appear in the same tag
  -		*/
  -		IAttribute *Iattr2b=phb->createAttribute(localname,"ns2","","Axis");
  -		IAttribute *Iattr3=phb->createAttribute(localname,"","","");	
  -		cout <<"name=" << phb->getAttributeValue("name","")<<endl;
  +		const AxisChar *localname="name";	
  +		IAttribute *Iattr1=phb->createAttribute(localname,prefix,temp);		
  +		IAttribute *Iattr2=phb->createAttribute(localname,"np1","","Axis");		
  +		IAttribute *Iattr3=phb->createAttribute(localname,"","","");		
   		cout << "np:name=" << phb->getAttributeValue(localname,prefix)<<endl;
   		cout << "np1:name=" << phb->getAttributeValue("name","np1")<<endl;
  -		if(phb->getAttributeValue(NULL,NULL)==NULL)
  -			cout<<"NULL returned for NULL argumets in getAttributeValue"<<endl;
  -		if(phb->getAttributeValue("name","nm")==NULL)
  -			cout<<"NULL returned for Non existing attribute"<<endl;
  -		if(phb->getAttributeValue("NAME","np1")==NULL)
  -			cout<<"NULL returned for Non existing Attribute"<<endl;
  +		cout <<"name=" << phb->getAttributeValue("name","")<<endl;
  +		if(phb->getAttributeValue(NULL,NULL)!=NULL)
  +			cout<<"NULL is not returned for NULL argumets in getAttributeValue"<<endl;
  +		if(phb->getAttributeValue("name","nm")!=NULL)
  +			cout<<"NULL is not returned for Non existing attribute"<<endl;
  +		if(phb->getAttributeValue("NAME","np1")!=NULL)
  +			cout<<"NULL is not returned for Non existing Attribute"<<endl;
   		if (strcmp(op, "add") == 0)
   		{
   			iResult=ws.add(i1, i2);