From 3a3a1492b1e5732e726bc724f35db0105e55beca Mon Sep 17 00:00:00 2001 From: "rayw%netscape.com" Date: Fri, 18 Jan 2002 18:44:13 +0000 Subject: [PATCH] Fixes to the test. SOAP is not part of default build. git-svn-id: svn://10.0.0.236/trunk@112438 18797224-902f-48f8-a5cc-f745e15eee43 --- .../soap/tests/soapheadlinenews.html | 30 +++++++++++-------- .../xmlextras/tests/soapheadlinenews.html | 30 +++++++++++-------- 2 files changed, 34 insertions(+), 26 deletions(-) diff --git a/mozilla/extensions/webservices/soap/tests/soapheadlinenews.html b/mozilla/extensions/webservices/soap/tests/soapheadlinenews.html index b2934d61b37..e0e571e5f15 100644 --- a/mozilla/extensions/webservices/soap/tests/soapheadlinenews.html +++ b/mozilla/extensions/webservices/soap/tests/soapheadlinenews.html @@ -16,6 +16,7 @@ user interfaces such as the one in this test. // Passed in as the response handler in the asynchronous case // and called directly (see below) in the synchronous case function oncompletion(resp, call, status) { + document.getElementById('BUTTON').value = "Call"; if (status != 0) { alert("Error completion: " + status); return true; @@ -32,8 +33,10 @@ function oncompletion(resp, call, status) { } else { var ret = resp.getParameters(false, {}); - var val = ret[0].value; - alert(val); + nw = window.open(); + nw.document.open(); + nw.document.write(ret[0].value); + nw.document.close(); } return true; } @@ -51,9 +54,10 @@ function makeCall(value) { // a struct parameter. It does not have a parameter wrapper because // we don't need it to be named s.encode(0, "ProcessSRL", "http://www.SoapClient.com/xml/SQLDataSoap.xsd", 0, null, - 1, new Array(new SOAPParameter("/xml/news.sri","SRLFile")), - new Array(new SOAPParameter(value,"RequestName"))); - if (currentCall != null) { currentCall.abort(); } + 2, new Array(new SOAPParameter("/xml/news.sri","SRLFile"), + new SOAPParameter(value,"RequestName"))); + if (currentCall != null) { currentCall.abort(); } + document.getElementById('BUTTON').value = "Wait..."; currentCall = s.asyncInvoke(oncompletion); } @@ -62,15 +66,15 @@ function makeCall(value) {
- + diff --git a/mozilla/extensions/xmlextras/tests/soapheadlinenews.html b/mozilla/extensions/xmlextras/tests/soapheadlinenews.html index b2934d61b37..e0e571e5f15 100644 --- a/mozilla/extensions/xmlextras/tests/soapheadlinenews.html +++ b/mozilla/extensions/xmlextras/tests/soapheadlinenews.html @@ -16,6 +16,7 @@ user interfaces such as the one in this test. // Passed in as the response handler in the asynchronous case // and called directly (see below) in the synchronous case function oncompletion(resp, call, status) { + document.getElementById('BUTTON').value = "Call"; if (status != 0) { alert("Error completion: " + status); return true; @@ -32,8 +33,10 @@ function oncompletion(resp, call, status) { } else { var ret = resp.getParameters(false, {}); - var val = ret[0].value; - alert(val); + nw = window.open(); + nw.document.open(); + nw.document.write(ret[0].value); + nw.document.close(); } return true; } @@ -51,9 +54,10 @@ function makeCall(value) { // a struct parameter. It does not have a parameter wrapper because // we don't need it to be named s.encode(0, "ProcessSRL", "http://www.SoapClient.com/xml/SQLDataSoap.xsd", 0, null, - 1, new Array(new SOAPParameter("/xml/news.sri","SRLFile")), - new Array(new SOAPParameter(value,"RequestName"))); - if (currentCall != null) { currentCall.abort(); } + 2, new Array(new SOAPParameter("/xml/news.sri","SRLFile"), + new SOAPParameter(value,"RequestName"))); + if (currentCall != null) { currentCall.abort(); } + document.getElementById('BUTTON').value = "Wait..."; currentCall = s.asyncInvoke(oncompletion); } @@ -62,15 +66,15 @@ function makeCall(value) { - +