~ubuntu-branches/ubuntu/hardy/php5/hardy-updates

« back to all changes in this revision

Viewing changes to ext/soap/tests/soap12/T42.phpt

  • Committer: Bazaar Package Importer
  • Author(s): Adam Conrad
  • Date: 2005-10-09 03:14:32 UTC
  • Revision ID: james.westby@ubuntu.com-20051009031432-kspik3lobxstafv9
Tags: upstream-5.0.5
ImportĀ upstreamĀ versionĀ 5.0.5

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
--TEST--
 
2
SOAP 1.2: T42 echoStructArray
 
3
--SKIPIF--
 
4
<?php require_once('skipif.inc'); ?>
 
5
--FILE--
 
6
<?php
 
7
$HTTP_RAW_POST_DATA = <<<EOF
 
8
<?xml version="1.0"?>
 
9
<env:Envelope xmlns:env="http://www.w3.org/2003/05/soap-envelope"
 
10
              xmlns:xsd="http://www.w3.org/2001/XMLSchema"
 
11
              xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
 
12
  <env:Body>
 
13
    <test:echoStructArray xmlns:test="http://example.org/ts-tests"
 
14
          env:encodingStyle="http://www.w3.org/2003/05/soap-encoding">
 
15
      <inputStructArray enc:itemType="ns1:SOAPStruct"
 
16
                        enc:arraySize="2"
 
17
                        xmlns:ns1="http://example.org/ts-tests/xsd"
 
18
                        xmlns:enc="http://www.w3.org/2003/05/soap-encoding">
 
19
        <item xsi:type="ns1:SOAPStruct">
 
20
          <varInt xsi:type="xsd:int">42</varInt>
 
21
          <varFloat xsi:type="xsd:float">0.005</varFloat>
 
22
          <varString xsi:type="xsd:string">hello world</varString>
 
23
        </item>
 
24
        <item xsi:type="ns1:SOAPStruct">
 
25
          <varInt xsi:type="xsd:int">43</varInt>
 
26
          <varFloat xsi:type="xsd:float">0.123</varFloat>
 
27
          <varString xsi:type="xsd:string">bye world</varString>
 
28
        </item>
 
29
      </inputStructArray>
 
30
    </test:echoStructArray>
 
31
  </env:Body>
 
32
</env:Envelope>
 
33
EOF;
 
34
include "soap12-test.inc";
 
35
?>
 
36
--EXPECT--
 
37
<?xml version="1.0" encoding="UTF-8"?>
 
38
<env:Envelope xmlns:env="http://www.w3.org/2003/05/soap-envelope" xmlns:ns1="http://example.org/ts-tests" xmlns:ns2="http://example.org/ts-tests/xsd" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:enc="http://www.w3.org/2003/05/soap-encoding"><env:Body xmlns:rpc="http://www.w3.org/2003/05/soap-rpc"><ns1:echoStructArrayResponse env:encodingStyle="http://www.w3.org/2003/05/soap-encoding"><rpc:result>return</rpc:result><return enc:itemType="ns2:SOAPStruct" enc:arraySize="2" xsi:type="ns2:ArrayOfSOAPStruct"><item xsi:type="ns2:SOAPStruct"><varString xsi:type="xsd:string">hello world</varString><varInt xsi:type="xsd:int">42</varInt><varFloat xsi:type="xsd:float">0.005</varFloat></item><item xsi:type="ns2:SOAPStruct"><varString xsi:type="xsd:string">bye world</varString><varInt xsi:type="xsd:int">43</varInt><varFloat xsi:type="xsd:float">0.123</varFloat></item></return></ns1:echoStructArrayResponse></env:Body></env:Envelope>
 
39
ok