Welcome to the "trac"-ing site of soap4r!
[soap4r] [httpclient] [openpgp4u] [pkcs1] [logger] [csv] [vtr]

Changeset 370

Show
Ignore:
Timestamp:
12/05/01 11:28:32 (7 years ago)
Author:
nakahiro
Message:

Added test servers.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/test/interopR2/base.rb

    r313 r370  
    5656MethodsGroupB = [ 
    5757  ['echoStructAsSimpleTypes', 
    58     ['in', 'inputStruct'], ['retval', 'outputString'], ['out', 'outputInteger'], ['out', 'outputFloat']], 
     58    ['in', 'inputStruct'], ['out', 'outputString'], ['out', 'outputInteger'], ['out', 'outputFloat']], 
    5959  ['echoSimpleTypesAsStruct', 
    6060    ['in', 'inputString'], ['in', 'inputInteger'], ['in', 'inputFloat'], ['retval', 'return']], 
  • trunk/test/interopR2/client4S4C.rb

    r282 r370  
    22 
    33$serverName = '4S4C' 
    4 $server = 'http://soap.4s4c.com/ilab/soap.asp
     4$server = 'http://www.4s4c.com/services/4s4c.ashx
    55 
    66require 'clientBase' 
  • trunk/test/interopR2/clientBase.rb

    r324 r370  
    1212$proxy = ARGV.shift || nil 
    1313 
     14=begin 
    1415require 'interopResultBase' 
    1516$testResultServer = 'http://www.jin.gr.jp/~nahi/Ruby/SOAP4R/rwikiInteropServer.cgi' 
     
    3637 
    3738$testResults = SOAPBuildersInteropResult::InteropResults.new( client, server ) 
     39=end 
    3840 
    3941$wireDumpDev = '' 
     
    109111    'OK' 
    110112  else 
    111     "Expected = " << expected.inspect << "\nActual = " << actual.inspect 
    112   end 
    113 end 
    114  
    115 def dump( var ) 
    116   if var.is_a?( Array ) 
    117     var.join( ", " ) 
    118   else 
    119     var.to_s 
     113    "Expected = " << expected.inspect << "  //  Actual = " << actual.inspect 
    120114  end 
    121115end 
     
    133127end 
    134128 
     129def getIdObj( obj ) 
     130  case obj 
     131  when Array 
     132    obj.collect { | ele | 
     133      getIdObj( ele ) 
     134    } 
     135  else 
     136    # String#== compares content of args. 
     137    "#{ obj.type }##{ obj.__id__ }" 
     138  end 
     139end 
     140 
     141def dumpTitle( title ) 
     142  $wireDumpLogFile << "##########\n# " << title << "\n\n" 
     143end 
     144 
    135145def dumpNormal( title, expected, actual ) 
    136146  result = assert( expected, actual ) 
     
    148158 
    149159def dumpResult( title, result, resultStr ) 
    150   $wireDumpLogFile << "##########\n# " << title << "\n\n" 
     160=begin 
    151161  $testResults.add( 
    152162    SOAPBuildersInteropResult::TestResult.new( 
     
    157167    ) 
    158168  ) 
     169=end 
    159170  $wireDumpLogFile << "Result: #{ resultStr || 'OK' }\n\n" 
    160171  $wireDumpLogFile << $wireDumpDev 
     
    186197 
    187198  title = 'echoVoid' 
     199  dumpTitle( title ) 
    188200  begin 
    189201    var =  drv.echoVoid() 
    190202    dumpNormal( title, nil, var ) 
    191   rescue Exception 
     203  rescue StandardError, NameError 
    192204    dumpException( title ) 
    193205  end 
    194206 
    195207  title = 'echoString' 
     208  dumpTitle( title ) 
    196209  begin 
    197210    arg = "SOAP4R Interoperability Test" 
    198211    var = drv.echoString( arg ) 
    199212    dumpNormal( title, arg, var ) 
    200   rescue Exception 
     213  rescue StandardError, NameError 
    201214    dumpException( title ) 
    202215  end 
    203216 
    204217  title = 'echoString (Leading and trailing whitespace)' 
     218  dumpTitle( title ) 
    205219  begin 
    206220    arg = "   SOAP4R\nInteroperability\nTest   " 
    207221    var = drv.echoString( arg ) 
    208222    dumpNormal( title, arg, var ) 
    209   rescue Exception 
     223  rescue StandardError, NameError 
    210224    dumpException( title ) 
    211225  end 
    212226 
    213227  title = 'echoString (EUC encoded)' 
     228  dumpTitle( title ) 
    214229  begin 
    215230    arg = "Hello (����panese) ������ 
    216231    var = drv.echoString( arg ) 
    217232    dumpNormal( title, arg, var ) 
    218   rescue Exception 
     233  rescue StandardError, NameError 
    219234    dumpException( title ) 
    220235  end 
    221236 
    222237  title = 'echoString (EUC encoded) again' 
     238  dumpTitle( title ) 
    223239  begin 
    224240    arg = "Hello (����panese) ������ 
    225241    var = drv.echoString( arg ) 
    226242    dumpNormal( title, arg, var ) 
    227   rescue Exception 
     243  rescue StandardError, NameError 
    228244    dumpException( title ) 
    229245  end 
    230246 
    231247  title = 'echoString (empty)' 
     248  dumpTitle( title ) 
    232249  begin 
    233250    arg = '' 
    234251    var = drv.echoString( arg ) 
    235252    dumpNormal( title, arg, var ) 
    236   rescue Exception 
     253  rescue StandardError, NameError 
    237254    dumpException( title ) 
    238255  end 
    239256 
    240257  title = 'echoString (space)' 
     258  dumpTitle( title ) 
    241259  begin 
    242260    arg = ' ' 
    243261    var = drv.echoString( arg ) 
    244262    dumpNormal( title, arg, var ) 
    245   rescue Exception 
     263  rescue StandardError, NameError 
    246264    dumpException( title ) 
    247265  end 
    248266 
    249267  title = 'echoString (whitespaces:\r \n \t \r \n \t)' 
     268  dumpTitle( title ) 
    250269  begin 
    251270    arg = "\r \n \t \r \n \t" 
    252271    var = drv.echoString( arg ) 
    253272    dumpNormal( title, arg, var ) 
    254   rescue Exception 
     273  rescue StandardError, NameError 
    255274    dumpException( title ) 
    256275  end 
    257276 
    258277  title = 'echoStringArray' 
     278  dumpTitle( title ) 
    259279  begin 
    260280    arg = StringArray[ "SOAP4R\n", " Interoperability ", "\tTest\t" ] 
    261281    var = drv.echoStringArray( arg ) 
    262282    dumpNormal( title, arg, var ) 
    263   rescue Exception 
     283  rescue StandardError, NameError 
    264284    dumpException( title ) 
    265285  end 
    266286 
    267287  title = 'echoStringArray (sparse)' 
     288  dumpTitle( title ) 
    268289  begin 
    269290    arg = [ nil, "SOAP4R\n", nil, " Interoperability ", nil, "\tTest\t", nil ] 
     
    272293    var = drv.echoStringArray( soapAry ) 
    273294    dumpNormal( title, arg, var ) 
    274   rescue Exception 
     295  rescue StandardError, NameError 
     296    dumpException( title ) 
     297  end 
     298 
     299  title = 'echoStringArray (multi-ref)' 
     300  dumpTitle( title ) 
     301  begin 
     302    str1 = "SOAP4R" 
     303    str2 = "SOAP4R" 
     304    arg = StringArray[ str1, str2, str1 ] 
     305    var = drv.echoStringArray( arg ) 
     306    dumpNormal( title, arg, var ) 
     307  rescue StandardError, NameError 
     308    dumpException( title ) 
     309  end 
     310 
     311  title = 'echoStringArray (multi-ref: elem1 == elem3)' 
     312  dumpTitle( title ) 
     313  begin 
     314    str1 = "SOAP4R" 
     315    str2 = "SOAP4R" 
     316    arg = StringArray[ str1, str2, str1 ] 
     317    var = drv.echoStringArray( arg ) 
     318    dumpNormal( title, getIdObj( var[0] ), getIdObj( var[2] )) 
     319  rescue StandardError, NameError 
     320    dumpException( title ) 
     321  end 
     322 
     323  title = 'echoStringArray (empty, multi-ref: elem1 == elem3)' 
     324  dumpTitle( title ) 
     325  begin 
     326    str1 = "" 
     327    str2 = "" 
     328    arg = StringArray[ str1, str2, str1 ] 
     329    var = drv.echoStringArray( arg ) 
     330    dumpNormal( title, getIdObj( var[0] ), getIdObj( var[2] )) 
     331  rescue StandardError, NameError 
     332    dumpException( title ) 
     333  end 
     334 
     335  title = 'echoStringArray (sparse, multi-ref)' 
     336  dumpTitle( title ) 
     337  begin 
     338    str = "SOAP4R" 
     339    arg = StringArray[ nil, nil, nil, nil, nil, str, nil, str ] 
     340    soapAry = SOAP::RPCUtils.ary2soap( arg, XSD::Namespace, XSD::StringLiteral, SOAPBuildersInterop::MappingRegistry ) 
     341    soapAry.sparse = true 
     342    var = drv.echoStringArray( soapAry ) 
     343    dumpNormal( title, arg, var ) 
     344  rescue StandardError, NameError 
    275345    dumpException( title ) 
    276346  end 
    277347 
    278348  title = 'echoInteger (Int: 123)' 
     349  dumpTitle( title ) 
    279350  begin 
    280351    arg = 123 
    281352    var = drv.echoInteger( arg ) 
    282353    dumpNormal( title, arg, var ) 
    283   rescue Exception 
     354  rescue StandardError, NameError 
    284355    dumpException( title ) 
    285356  end 
    286357 
    287358  title = 'echoInteger (Int: 2147483647)' 
     359  dumpTitle( title ) 
    288360  begin 
    289361    arg = 2147483647 
    290362    var = drv.echoInteger( arg ) 
    291363    dumpNormal( title, arg, var ) 
    292   rescue Exception 
     364  rescue StandardError, NameError 
    293365    dumpException( title ) 
    294366  end 
    295367 
    296368  title = 'echoInteger (Int: -2147483648)' 
     369  dumpTitle( title ) 
    297370  begin 
    298371    arg = -2147483648 
    299372    var = drv.echoInteger( arg ) 
    300373    dumpNormal( title, arg, var ) 
    301   rescue Exception 
     374  rescue StandardError, NameError 
    302375    dumpException( title ) 
    303376  end 
    304377 
    305378  title = 'echoIntegerArray' 
     379  dumpTitle( title ) 
    306380  begin 
    307381    arg = IntArray[ 1, 2, 3 ] 
    308382    var = drv.echoIntegerArray( arg ) 
    309383    dumpNormal( title, arg, var ) 
    310   rescue Exception 
    311     dumpException( title ) 
    312   end 
    313  
    314 #  title = 'echoIntegerArray (nil)' 
    315 #  begin 
    316 #    arg = IntArray[ nil, nil, nil ] 
    317 #    var = drv.echoIntegerArray( arg ) 
    318 #    dumpNormal( title, arg, var ) 
    319 #  rescue Exception 
    320 #    dumpException( title ) 
    321 #  end 
     384  rescue StandardError, NameError 
     385    dumpException( title ) 
     386  end 
     387 
     388  title = 'echoIntegerArray (nil)' 
     389  dumpTitle( title ) 
     390  begin 
     391    arg = IntArray[ nil, nil, nil ] 
     392    var = drv.echoIntegerArray( arg ) 
     393    dumpNormal( title, arg, var ) 
     394  rescue StandardError, NameError 
     395    dumpException( title ) 
     396  end 
    322397 
    323398  title = 'echoIntegerArray (empty)' 
     399  dumpTitle( title ) 
    324400  begin 
    325401    arg = SOAP::SOAPArray.new( XSD::IntLiteral ) 
     
    327403    var = drv.echoIntegerArray( arg ) 
    328404    dumpNormal( title, [], var ) 
    329   rescue Exception 
     405  rescue StandardError, NameError 
    330406    dumpException( title ) 
    331407  end 
    332408 
    333409  title = 'echoIntegerArray (sparse)' 
     410  dumpTitle( title ) 
    334411  begin 
    335412    arg = [ nil, 1, nil, 2, nil, 3, nil ] 
     
    338415    var = drv.echoIntegerArray( soapAry ) 
    339416    dumpNormal( title, arg, var ) 
    340   rescue Exception 
     417  rescue StandardError, NameError 
    341418    dumpException( title ) 
    342419  end 
    343420 
    344421  title = 'echoFloat' 
     422  dumpTitle( title ) 
    345423  begin 
    346424    arg = 3.14159265358979 
    347425    var = drv.echoFloat( arg ) 
    348426    dumpNormal( title, arg, var ) 
    349   rescue Exception 
     427  rescue StandardError, NameError 
    350428    dumpException( title ) 
    351429  end 
    352430 
    353431  title = 'echoFloat (scientific notation)' 
     432  dumpTitle( title ) 
    354433  begin 
    355434    arg = 12.34e36 
    356435    var = drv.echoFloat( arg ) 
    357436    dumpNormal( title, arg, var ) 
    358   rescue Exception 
     437  rescue StandardError, NameError 
    359438    dumpException( title ) 
    360439  end 
    361440 
    362441  title = 'echoFloat (positive lower boundary)' 
     442  dumpTitle( title ) 
    363443  begin 
    364444    arg = 1.4e-45 
    365445    var = drv.echoFloat( arg ) 
    366446    dumpNormal( title, arg, var ) 
    367   rescue Exception 
     447  rescue StandardError, NameError 
    368448    dumpException( title ) 
    369449  end 
    370450 
    371451  title = 'echoFloat (negative lower boundary)' 
     452  dumpTitle( title ) 
    372453  begin 
    373454    arg = -1.4e-45 
    374455    var = drv.echoFloat( arg ) 
    375456    dumpNormal( title, arg, var ) 
    376   rescue Exception 
     457  rescue StandardError, NameError 
    377458    dumpException( title ) 
    378459  end 
    379460 
    380461  title = 'echoFloat (special values: NaN)' 
     462  dumpTitle( title ) 
    381463  begin 
    382464    arg = 0.0/0.0 
    383465    var = drv.echoFloat( arg ) 
    384466    dumpNormal( title, arg, var ) 
    385   rescue Exception 
     467  rescue StandardError, NameError 
    386468    dumpException( title ) 
    387469  end 
    388470 
    389471  title = 'echoFloat (special values: INF)' 
     472  dumpTitle( title ) 
    390473  begin 
    391474    arg = 1.0/0.0 
    392475    var = drv.echoFloat( arg ) 
    393476    dumpNormal( title, arg, var ) 
    394   rescue Exception 
     477  rescue StandardError, NameError 
    395478    dumpException( title ) 
    396479  end 
    397480 
    398481  title = 'echoFloat (special values: -INF)' 
     482  dumpTitle( title ) 
    399483  begin 
    400484    arg = -1.0/0.0 
    401485    var = drv.echoFloat( arg ) 
    402486    dumpNormal( title, arg, var ) 
    403   rescue Exception 
     487  rescue StandardError, NameError 
    404488    dumpException( title ) 
    405489  end 
    406490 
    407491  title = 'echoFloatArray' 
     492  dumpTitle( title ) 
    408493  begin 
    409494    arg = FloatArray[ 0.0001, 1000.0, 0.0 ] 
    410495    var = drv.echoFloatArray( arg ) 
    411496    dumpNormal( title, arg, var ) 
    412   rescue Exception 
     497  rescue StandardError, NameError 
    413498    dumpException( title ) 
    414499  end 
    415500 
    416501  title = 'echoFloatArray (special values: NaN, INF, -INF)' 
     502  dumpTitle( title ) 
    417503  begin 
    418504    nan = 0.0/0.0 
     
    422508    var = drv.echoFloatArray( arg ) 
    423509    dumpNormal( title, arg, var ) 
    424   rescue Exception 
     510  rescue StandardError, NameError 
    425511    dumpException( title ) 
    426512  end 
    427513 
    428514  title = 'echoFloatArray (sparse)' 
     515  dumpTitle( title ) 
    429516  begin 
    430517    arg = [ nil, nil, 0.0001, 1000.0, 0.0, nil, nil ] 
     
    433520    var = drv.echoFloatArray( soapAry ) 
    434521    dumpNormal( title, arg, var ) 
    435   rescue Exception 
     522  rescue StandardError, NameError 
    436523    dumpException( title ) 
    437524  end 
    438525 
    439526  title = 'echoStruct' 
     527  dumpTitle( title ) 
    440528  begin 
    441529    arg = SOAPStruct.new( 1, 1.1, "a" ) 
    442530    var = drv.echoStruct( arg ) 
    443531    dumpNormal( title, arg, var ) 
    444   rescue Exception 
    445     dumpException( title ) 
    446   end 
    447  
    448 #  title = 'echoStruct (nil members)' 
    449 #  begin 
    450 #    arg = SOAPStruct.new( nil, nil, nil ) 
    451 #    var = drv.echoStruct( arg ) 
    452 #    dumpNormal( title, arg, var ) 
    453 #  rescue Exception 
    454 #    dumpException( title ) 
    455 #  end 
     532  rescue StandardError, NameError 
     533    dumpException( title ) 
     534  end 
     535 
     536  title = 'echoStruct (nil members)' 
     537  dumpTitle( title ) 
     538  begin 
     539    arg = SOAPStruct.new( nil, nil, nil ) 
     540    var = drv.echoStruct( arg ) 
     541    dumpNormal( title, arg, var ) 
     542  rescue StandardError, NameError 
     543    dumpException( title ) 
     544  end 
    456545 
    457546  title = 'echoStructArray' 
     547  dumpTitle( title ) 
    458548  begin 
    459549    s1 = SOAPStruct.new( 1, 1.1, "a" ) 
     
    463553    var = drv.echoStructArray( arg ) 
    464554    dumpNormal( title, arg, var )  
    465   rescue Exception 
     555  rescue StandardError, NameError 
    466556    dumpException( title ) 
    467557  end 
    468558 
    469559  title = 'echoStructArray (anyType Array)' 
     560  dumpTitle( title ) 
    470561  begin 
    471562    s1 = SOAPStruct.new( 1, 1.1, "a" ) 
     
    475566    var = drv.echoStructArray( arg ) 
    476567    dumpNormal( title, arg, var )  
    477   rescue Exception 
     568  rescue StandardError, NameError 
    478569    dumpException( title ) 
    479570  end 
    480571 
    481572  title = 'echoStructArray (sparse)' 
     573  dumpTitle( title ) 
    482574  begin 
    483575    s1 = SOAPStruct.new( 1, 1.1, "a" ) 
    484576    s2 = SOAPStruct.new( 2, 2.2, "b" ) 
    485577    s3 = SOAPStruct.new( 3, 3.3, "c" ) 
    486     arg = [ s1, s2, s3 ] 
     578    arg = [ nil, s1, s2, s3 ] 
    487579    soapAry = SOAP::RPCUtils.ary2soap( arg, TypeNS, "SOAPStruct", SOAPBuildersInterop::MappingRegistry )  
    488580    soapAry.sparse = true 
    489581    var = drv.echoStructArray( soapAry ) 
    490582    dumpNormal( title, arg, var )  
    491   rescue Exception 
    492     dumpException( title ) 
    493   end 
    494  
    495 =begin 
    496   title = 'echoStructArray (2D Array)' 
     583  rescue StandardError, NameError 
     584    dumpException( title ) 
     585  end 
     586 
     587  title = 'echoStructArray (multi-ref)' 
     588  dumpTitle( title ) 
    497589  begin 
    498590    s1 = SOAPStruct.new( 1, 1.1, "a" ) 
    499591    s2 = SOAPStruct.new( 2, 2.2, "b" ) 
    500     s3 = SOAPStruct.new( 3, 3.3, "c" ) 
    501     arg = [ 
    502       [ s1, nil, s2 ], 
    503       [ nil, s2, s3 ], 
    504     ] 
    505     md = SOAP::RPCUtils.ary2md( arg, 2, XSD::Namespace, XSD::AnyTypeLiteral, SOAPBuildersInterop::MappingRegistry ) 
    506  
    507     var = drv.echoStructArray( md ) 
     592    arg = SOAPStructArray[ s1, s1, s2 ] 
     593    var = drv.echoStructArray( arg ) 
    508594    dumpNormal( title, arg, var )  
    509   rescue Exception 
    510     dumpException( title ) 
    511   end 
    512  
    513   title = 'echoStructArray (2D Array, sparse)' 
     595  rescue StandardError, NameError 
     596    dumpException( title ) 
     597  end 
     598 
     599  title = 'echoStructArray (multi-ref: elem1 == elem2)' 
     600  dumpTitle( title ) 
    514601  begin 
    515602    s1 = SOAPStruct.new( 1, 1.1, "a" ) 
    516603    s2 = SOAPStruct.new( 2, 2.2, "b" ) 
    517     s3 = SOAPStruct.new( 3, 3.3, "c" ) 
    518     arg = [ 
    519       [ s1, nil, s2 ], 
    520       [ nil, s2, s3 ], 
    521     ] 
    522     md = SOAP::RPCUtils.ary2md( arg, 2, TypeNS, "SOAPStruct", SOAPBuildersInterop::MappingRegistry ) 
    523     md.sparse = true 
    524  
    525     var = drv.echoStructArray( md ) 
    526     dumpNormal( title, arg, var )  
    527   rescue Exception 
    528     dumpException( title ) 
    529   end 
    530  
    531   title = 'echoStructArray (anyType, 2D Array, sparse)' 
     604    arg = SOAPStructArray[ s1, s1, s2 ] 
     605    var = drv.echoStructArray( arg ) 
     606    dumpNormal( title, getIdObj( var[0] ), getIdObj( var[1] ))  
     607  rescue StandardError, NameError 
     608    dumpException( title ) 
     609  end 
     610 
     611  title = 'echoStructArray (anyType Array, multi-ref: elem2 == elem3)' 
     612  dumpTitle( title ) 
    532613  begin 
    533614    s1 = SOAPStruct.new( 1, 1.1, "a" ) 
    534615    s2 = SOAPStruct.new( 2, 2.2, "b" ) 
    535     s3 = SOAPStruct.new( 3, 3.3, "c" ) 
    536     arg = [ 
    537       [ s1, nil, s2 ], 
    538       [ nil, s2, s3 ], 
    539     ] 
    540     md = SOAP::RPCUtils.ary2md( arg, 2, XSD::Namespace, XSD::AnyTypeLiteral, SOAPBuildersInterop::MappingRegistry ) 
    541     md.sparse = true 
    542  
    543     var = drv.echoStructArray( md ) 
     616    arg = [ s1, s2, s2 ] 
     617    var = drv.echoStructArray( arg ) 
     618    dumpNormal( title, getIdObj( var[1] ), getIdObj( var[2] ))  
     619  rescue StandardError, NameError 
     620    dumpException( title ) 
     621  end 
     622 
     623  title = 'echoStructArray (sparse, multi-ref)' 
     624  dumpTitle( title ) 
     625  begin 
     626    s1 = SOAPStruct.new( 1, 1.1, "a" ) 
     627    s2 = SOAPStruct.new( 2, 2.2, "b" ) 
     628    arg = [ nil, s1, nil, nil, s2, nil, s2 ] 
     629    soapAry = SOAP::RPCUtils.ary2soap( arg, TypeNS, "SOAPStruct", SOAPBuildersInterop::MappingRegistry )  
     630    soapAry.sparse = true 
     631    var = drv.echoStructArray( soapAry ) 
    544632    dumpNormal( title, arg, var )  
    545   rescue Exception 
    546     dumpException( title ) 
    547   end 
    548 =end 
     633  rescue StandardError, NameError 
     634    dumpException( title ) 
     635  end 
     636 
     637  title = 'echoStructArray (sparse, multi-ref: elem5 == elem7)' 
     638  dumpTitle( title ) 
     639  begin 
     640    s1 = SOAPStruct.new( 1, 1.1, "a" ) 
     641    s2 = SOAPStruct.new( 2, 2.2, "b" ) 
     642    arg = [ nil, s1, nil, nil, s2, nil, s2 ] 
     643    soapAry = SOAP::RPCUtils.ary2soap( arg, TypeNS, "SOAPStruct", SOAPBuildersInterop::MappingRegistry )  
     644    soapAry.sparse = true 
     645    var = drv.echoStructArray( soapAry ) 
     646    dumpNormal( title, getIdObj( var[4] ), getIdObj( var[6] ))  
     647  rescue StandardError, NameError 
     648    dumpException( title ) 
     649  end 
     650 
     651  title = 'echoStructArray (multi-ref: varString of elem1 == varString of elem2)' 
     652  dumpTitle( title ) 
     653  begin 
     654    str1 = "a" 
     655    str2 = "a" 
     656    s1 = SOAPStruct.new( 1, 1.1, str1 ) 
     657    s2 = SOAPStruct.new( 2, 2.2, str1 ) 
     658    s3 = SOAPStruct.new( 3, 3.3, str2 ) 
     659    arg = SOAPStructArray[ s1, s2, s3 ] 
     660    var = drv.echoStructArray( arg ) 
     661    dumpNormal( title, getIdObj( var[0].varString ), getIdObj( var[1].varString ))  
     662  rescue StandardError, NameError 
     663    dumpException( title ) 
     664  end 
     665 
     666  title = 'echoStructArray (anyType Array, multi-ref: varString of elem2 == varString of elem3)' 
     667  dumpTitle( title ) 
     668  begin 
     669    str1 = "b" 
     670    str2 = "b" 
     671    s1 = SOAPStruct.new( 1, 1.1, str2 ) 
     672    s2 = SOAPStruct.new( 2, 2.2, str1 ) 
     673    s3 = SOAPStruct.new( 3, 3.3, str1 ) 
     674    arg = [ s1, s2, s3 ] 
     675    var = drv.echoStructArray( arg ) 
     676    dumpNormal( title, getIdObj( var[1].varString ), getIdObj( var[2].varString ))  
     677  rescue StandardError, NameError 
     678    dumpException( title ) 
     679  end 
     680 
     681  title = 'echoStructArray (sparse, multi-ref: varString of elem5 == varString of elem7)' 
     682  dumpTitle( title ) 
     683  begin 
     684    str1 = "c" 
     685    str2 = "c" 
     686    s1 = SOAPStruct.new( 1, 1.1, str2 ) 
     687    s2 = SOAPStruct.new( 2, 2.2, str1 ) 
     688    s3 = SOAPStruct.new( 3, 3.3, str1 ) 
     689    arg = [ nil, s1, nil, nil, s2, nil, s3 ] 
     690    soapAry = SOAP::RPCUtils.ary2soap( arg, TypeNS, "SOAPStruct", SOAPBuildersInterop::MappingRegistry )  
     691    soapAry.sparse = true 
     692    var = drv.echoStructArray( soapAry ) 
     693    dumpNormal( title, getIdObj( var[4].varString ), getIdObj( var[6].varString ))  
     694  rescue StandardError, NameError 
     695    dumpException( title ) 
     696  end 
     697 
     698#  title = 'echoStructArray (2D Array)' 
     699#  dumpTitle( title ) 
     700#  begin 
     701#    s1 = SOAPStruct.new( 1, 1.1, "a" ) 
     702#    s2 = SOAPStruct.new( 2, 2.2, "b" ) 
     703#    s3 = SOAPStruct.new( 3, 3.3, "c" ) 
     704#    arg = [ 
     705#      [ s1, nil, s2 ], 
     706#      [ nil, s2, s3 ], 
     707#    ] 
     708#    md = SOAP::RPCUtils.ary2md( arg, 2, XSD::Namespace, XSD::AnyTypeLiteral, SOAPBuildersInterop::MappingRegistry ) 
     709
     710#    var = drv.echoStructArray( md ) 
     711#    dumpNormal( title, arg, var )  
     712#  rescue StandardError, NameError 
     713#    dumpException( title ) 
     714#  end 
     715
     716#  title = 'echoStructArray (2D Array, sparse)' 
     717#  dumpTitle( title ) 
     718#  begin 
     719#    s1 = SOAPStruct.new( 1, 1.1, "a" ) 
     720#    s2 = SOAPStruct.new( 2, 2.2, "b" ) 
     721#    s3 = SOAPStruct.new( 3, 3.3, "c" ) 
     722#    arg = [ 
     723#      [ s1, nil, s2 ], 
     724#      [ nil, s2, s3 ], 
     725#    ] 
     726#    md = SOAP::RPCUtils.ary2md( arg, 2, TypeNS, "SOAPStruct", SOAPBuildersInterop::MappingRegistry ) 
     727##    md.sparse = true 
     728
     729#    var = drv.echoStructArray( md ) 
     730#    dumpNormal( title, arg, var )  
     731#  rescue StandardError, NameError 
     732#    dumpException( title ) 
     733#  end 
     734
     735#  title = 'echoStructArray (anyType, 2D Array, sparse)' 
     736#  dumpTitle( title ) 
     737#  begin 
     738#    s1 = SOAPStruct.new( 1, 1.1, "a" ) 
     739#    s2 = SOAPStruct.new( 2, 2.2, "b" ) 
     740#    s3 = SOAPStruct.new( 3, 3.3, "c" ) 
     741#    arg = [ 
     742#      [ s1, nil, s2 ], 
     743#      [ nil, s2, s3 ], 
     744#    ] 
     745#    md = SOAP::RPCUtils.ary2md( arg, 2, XSD::Namespace, XSD::AnyTypeLiteral, SOAPBuildersInterop::MappingRegistry ) 
     746#    md.sparse = true 
     747
     748#    var = drv.echoStructArray( md ) 
     749#    dumpNormal( title, arg, var )  
     750#  rescue StandardError, NameError 
     751#    dumpException( title ) 
     752#  end 
    549753 
    550754  title = 'echoDate (now)' 
     755  dumpTitle( title ) 
    551756  begin 
    552757    t = Time.now.gmtime 
     
    554759    var = drv.echoDate( arg ) 
    555760    dumpNormal( title, arg.to_s, var.to_s ) 
    556   rescue Exception 
     761  rescue StandardError, NameError 
    557762    dumpException( title ) 
    558763  end 
    559764 
    560765  title = 'echoDate (before 1970: 1-01-01T00:00:00Z)' 
     766  dumpTitle( title ) 
    561767  begin 
    562768    t = Time.now.gmtime 
     
    564770    var = drv.echoDate( arg ) 
    565771    dumpNormal( title, arg.to_s, var.to_s ) 
    566   rescue Exception 
     772  rescue StandardError, NameError 
    567773    dumpException( title ) 
    568774  end 
    569775 
    570776  title = 'echoDate (after 2038: 2038-12-31T00:00:00Z)' 
     777  dumpTitle( title ) 
    571778  begin 
    572779    t = Time.now.gmtime 
     
    574781    var = drv.echoDate( arg ) 
    575782    dumpNormal( title, arg.to_s, var.to_s ) 
    576   rescue Exception 
     783  rescue StandardError, NameError 
    577784    dumpException( title ) 
    578785  end 
    579786 
    580787  title = 'echoDate (negative: -10-01-01T00:00:00Z)' 
     788  dumpTitle( title ) 
    581789  begin 
    582790    t = Time.now.gmtime 
     
    584792    var = drv.echoDate( arg ) 
    585793    dumpNormal( title, arg.to_s, var.to_s ) 
    586   rescue Exception 
     794  rescue StandardError, NameError 
    587795    dumpException( title ) 
    588796  end 
    589797 
    590798  title = 'echoDate (time precision: msec)' 
     799  dumpTitle( title ) 
    591800  begin 
    592801    arg = SOAP::SOAPDateTime.new( '2001-06-16T18:13:40.012' ) 
     
    594803    var = drv.echoDate( arg ) 
    595804    dumpNormal( title, argDate, var ) 
    596   rescue Exception 
     805  rescue StandardError, NameError 
    597806    dumpException( title ) 
    598807  end 
    599808 
    600809  title = 'echoDate (time precision: long)' 
     810  dumpTitle( title ) 
    601811  begin 
    602812    arg = SOAP::SOAPDateTime.new( '2001-06-16T18:13:40.0000000000123456789012345678900000000000' ) 
     
    604814    var = drv.echoDate( arg ) 
    605815    dumpNormal( title, argDate, var ) 
    606   rescue Exception 
     816  rescue StandardError, NameError 
    607817    dumpException( title ) 
    608818  end 
    609819 
    610820  title = 'echoDate (client side TZ conversion)' 
     821  dumpTitle( title ) 
    611822  begin 
    612823    arg = SOAP::SOAPDateTime.new( '2001-06-16T18:13:40-07:00' ) 
     
    614825    var = drv.echoDate( arg ) 
    615826    dumpNormal( title, argNormalized.to_s, var.to_s ) 
    616   rescue Exception 
     827  rescue StandardError, NameError 
    617828    dumpException( title ) 
    618829  end 
    619830 
    620831  title = 'echoBase64 (xsd:base64Binary)' 
     832  dumpTitle( title ) 
    621833  begin 
    622834    str = "Hello (����panese) ������ 
     
    625837    var = drv.echoBase64( arg ) 
    626838    dumpNormal( title, str, var ) 
    627   rescue Exception 
     839  rescue StandardError, NameError 
    628840    dumpException( title ) 
    629841  end 
    630842 
    631843  title = 'echoBase64 (xsd:base64Binary, empty)' 
     844  dumpTitle( title ) 
    632845  begin 
    633846    str = "" 
     
    636849    var = drv.echoBase64( arg ) 
    637850    dumpNormal( title, str, var ) 
    638   rescue Exception 
     851  rescue StandardError, NameError 
    639852    dumpException( title ) 
    640853  end 
    641854 
    642855  title = 'echoBase64 (SOAP-ENC:base64)' 
     856  dumpTitle( title ) 
    643857  begin 
    644858    str = "Hello (����panese) ������ 
     
    646860    var = drv.echoBase64( arg ) 
    647861    dumpNormal( title, str, var ) 
    648   rescue Exception 
     862  rescue StandardError, NameError 
    649863    dumpException( title ) 
    650864  end 
    651865 
    652866  title = 'echoHexBinary' 
     867  dumpTitle( title ) 
    653868  begin 
    654869    str = "Hello (����panese) ������ 
     
    656871    var = drv.echoHexBinary( arg ) 
    657872    dumpNormal( title, str, var ) 
    658   rescue Exception 
     873  rescue StandardError, NameError 
    659874    dumpException( title ) 
    660875  end 
    661876 
    662877  title = 'echoHexBinary(empty)' 
     878  dumpTitle( title ) 
    663879  begin 
    664880    str = "" 
     
    666882    var = drv.echoHexBinary( arg ) 
    667883    dumpNormal( title, str, var ) 
    668   rescue Exception 
     884  rescue StandardError, NameError 
    669885    dumpException( title ) 
    670886  end 
    671887 
    672888  title = 'echoBoolean (true)' 
     889  dumpTitle( title ) 
    673890  begin 
    674891    arg = true 
    675892    var = drv.echoBoolean( arg ) 
    676893    dumpNormal( title, arg, var ) 
    677   rescue Exception 
     894  rescue StandardError, NameError 
    678895    dumpException( title ) 
    679896  end 
    680897 
    681898  title = 'echoBoolean (false)' 
     899  dumpTitle( title ) 
    682900  begin 
    683901    arg = false 
    684902    var = drv.echoBoolean( arg ) 
    685903    dumpNormal( title, arg, var ) 
    686   rescue Exception 
     904  rescue StandardError, NameError 
    687905    dumpException( title ) 
    688906  end 
    689907 
    690908#  title = 'echoDouble' 
     909#  dumpTitle( title ) 
    691910#  begin 
    692911#    arg = 3.14159265358979 
    693912#    var = drv.echoDouble( arg ) 
    694913#    dumpNormal( title, arg, var ) 
    695 #  rescue Exception 
     914#  rescue StandardError, NameError 
    696915#    dumpException( title ) 
    697916#  end 
    698917 
    699918  title = 'echoDecimal (123456)' 
     919  dumpTitle( title ) 
    700920  begin 
    701921    arg = "12345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890" 
     
    703923    normalized = arg 
    704924    dumpNormal( title, normalized, var ) 
    705   rescue Exception 
     925  rescue StandardError, NameError 
    706926    dumpException( title ) 
    707927  end 
    708928 
    709929  title = 'echoDecimal (+0.123)' 
     930  dumpTitle( title ) 
    710931  begin 
    711932    arg = "+0.12345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890" 
     
    713934    normalized = arg.sub( /0$/, '' ).sub( /^\+/, '' ) 
    714935    dumpNormal( title, normalized, var ) 
    715   rescue Exception 
     936  rescue StandardError, NameError 
    716937    dumpException( title ) 
    717938  end 
    718939 
    719940  title = 'echoDecimal (.00000123)' 
     941  dumpTitle( title ) 
    720942  begin 
    721943    arg = ".0000012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890" 
     
    723945    normalized = '0' << arg.sub( /0$/, '' ) 
    724946    dumpNormal( title, normalized, var ) 
    725   rescue Exception 
     947  rescue StandardError, NameError 
    726948    dumpException( title ) 
    727949  end 
    728950 
    729951  title = 'echoDecimal (-123.456)' 
     952  dumpTitle( title ) 
    730953  begin 
    731954    arg = "-12345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123.45678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789" 
    732955    var = drv.echoDecimal( SOAP::SOAPDecimal.new( arg )) 
    733956    dumpNormal( title, arg, var ) 
    734   rescue Exception 
     957  rescue StandardError, NameError 
    735958    dumpException( title ) 
    736959  end 
    737960 
    738961  title = 'echoDecimal (-123.)' 
     962  dumpTitle( title ) 
    739963  begin 
    740964    arg = "-12345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890." 
     
    742966    var = drv.echoDecimal( SOAP::SOAPDecimal.new( arg )) 
    743967    dumpNormal( title, normalized, var ) 
    744   rescue Exception 
    745     dumpException( title ) 
    746   end 
     968  rescue StandardError, NameError 
     969    dumpException( title ) 
     970  end 
     971 
    747972 
    748973if $test_echoMap 
    749974 
    750975  title = 'echoMap' 
     976  dumpTitle( title ) 
    751977  begin 
    752978    arg = { "a" => 1, "b" => 2 } 
    753979    var = drv.echoMap( arg ) 
    754980    dumpNormal( title, arg, var ) 
    755   rescue Exception 
     981  rescue StandardError, NameError 
    756982    dumpException( title ) 
    757983  end 
    758984 
    759985  title = 'echoMap (boolean, base64, nil, float)' 
     986  dumpTitle( title ) 
    760987  begin 
    761988    arg = { true => "\0", "\0" => nil, nil => 0.0001, 0.0001 => false } 
    762989    var = drv.echoMap( arg ) 
    763990    dumpNormal( title, arg, var ) 
    764   rescue Exception 
     991  rescue StandardError, NameError 
    765992    dumpException( title ) 
    766993  end 
    767994 
    768995  title = 'echoMap (multibyte char)' 
     996  dumpTitle( title ) 
    769997  begin 
    770998    arg = { "Hello (����panese) ������ => 1, 1 => "Hello (����panese) ������ } 
    771999    var = drv.echoMap( arg ) 
    7721000    dumpNormal( title, arg, var ) 
    773   rescue Exception 
     1001  rescue StandardError, NameError 
     1002    dumpException( title ) 
     1003  end 
     1004 
     1005  title = 'echoMap (Struct)' 
     1006  dumpTitle( title ) 
     1007  begin 
     1008    obj = SOAPStruct.new( 1, 1.1, "a" ) 
     1009    arg = { 1 => obj, 2 => obj } 
     1010    var = drv.echoMap( arg ) 
     1011    dumpNormal( title, arg, var ) 
     1012  rescue StandardError, NameError 
     1013    dumpException( title ) 
     1014  end 
     1015 
     1016  title = 'echoMap (multi-ref: value for key "a" == value for key "b")' 
     1017  dumpTitle( title ) 
     1018  begin 
     1019    value = "c" 
     1020    arg = { "a" => value, "b" => value } 
     1021    var = drv.echoMap( arg ) 
     1022    dumpNormal( title, getIdObj( var["a"] ), getIdObj( var["b"] )) 
     1023  rescue StandardError, NameError 
     1024    dumpException( title ) 
     1025  end 
     1026 
     1027  title = 'echoMap (Struct, multi-ref: varString of a key == varString of a value)' 
     1028  dumpTitle( title ) 
     1029  begin 
     1030    str = "" 
     1031    obj = SOAPStruct.new( 1, 1.1, str ) 
     1032    arg = { obj => "1", "1" => obj } 
     1033    var = drv.echoMap( arg ) 
     1034    dumpNormal( title, getIdObj( var.index("1").varString ), getIdObj( var.fetch("1").varString )) 
     1035  rescue StandardError, NameError 
    7741036    dumpException( title ) 
    7751037  end 
    7761038 
    7771039  title = 'echoMapArray' 
    778   begin 
    779     map = { "a" => 1, "b" => 2 } 
    780     arg = [ map, map, map ] 
     1040  dumpTitle( title ) 
     1041  begin 
     1042    map1 = { "a" => 1, "b" => 2 } 
     1043    map2 = { "a" => 1, "b" => 2 } 
     1044    map3 = { "a" => 1, "b" => 2 } 
     1045    arg = [ map1, map2, map3 ] 
    7811046    var = drv.echoMapArray( arg ) 
    7821047    dumpNormal( title, arg, var ) 
    783   rescue Exception 
     1048  rescue StandardError, NameError 
    7841049    dumpException( title ) 
    7851050  end 
    7861051 
    7871052  title = 'echoMapArray (boolean, base64, nil, float)' 
    788   begin 
    789     map = { true => "\0", "\0" => nil, nil => 0.0001, 0.0001 => false } 
    790     arg = [ map, map, map ] 
     1053  dumpTitle( title ) 
     1054  begin 
     1055    map1 = { true => "\0", "\0" => nil, nil => 0.0001, 0.0001 => false } 
     1056    map2 = { true => "\0", "\0" => nil, nil => 0.0001, 0.0001 => false } 
     1057    map3 = { true => "\0", "\0" => nil, nil => 0.0001, 0.0001 => false } 
     1058    arg = [ map1, map2, map3 ] 
    7911059    var = drv.echoMapArray( arg ) 
    7921060    dumpNormal( title, arg, var ) 
    793   rescue Exception 
     1061  rescue StandardError, NameError 
    7941062    dumpException( title ) 
    7951063  end 
    7961064 
    7971065  title = 'echoMapArray (sparse)' 
    798   begin 
    799     map = { "a" => 1, "b" => 2 } 
    800 &