From cd7fb8b2ae3b11877007aef3dd0ee1e9c74a4e69 Mon Sep 17 00:00:00 2001 From: Andreas Fitzek Date: Wed, 14 May 2014 11:39:31 +0200 Subject: PDF-AS Wev Client Test changes --- .../at/gv/egiz/pdfas/web/client/test/SimpleTest.java | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) (limited to 'pdf-as-web-client/src/test/java/at/gv') diff --git a/pdf-as-web-client/src/test/java/at/gv/egiz/pdfas/web/client/test/SimpleTest.java b/pdf-as-web-client/src/test/java/at/gv/egiz/pdfas/web/client/test/SimpleTest.java index e7696ceb..8573b224 100644 --- a/pdf-as-web-client/src/test/java/at/gv/egiz/pdfas/web/client/test/SimpleTest.java +++ b/pdf-as-web-client/src/test/java/at/gv/egiz/pdfas/web/client/test/SimpleTest.java @@ -35,11 +35,16 @@ public class SimpleTest { // URL endpoint = new // URL("http://demo.egiz.gv.at/demoportal-pdf_as/wssign?wsdl"); + //URL endpoint = new URL( + // "http://localhost:8080/pdf-as-web/wssign?wsdl"); URL endpoint = new URL( - "http://localhost:8080/pdf-as-web/wssign?wsdl"); + "http://192.168.56.10/pdf-as-web/wssign?wsdl"); RemotePDFSigner signer = new RemotePDFSigner(endpoint, false); + System.out.println("Simple Request:"); + byte[] outputFile = signer.signPDFDokument(inputData, signParameters); + /* * System.out.println("Simple Request:"); byte[] outputFile = * signer.signPDFDokument(inputData, signParameters); @@ -60,6 +65,7 @@ public class SimpleTest { * response.getError()); } */ + /* List bulk = new ArrayList(); for (int i = 0; i < 10; i++) { bulk.add(request); @@ -77,12 +83,7 @@ public class SimpleTest { PDFASSignResponse bulkresponse = responses .getSignResponses().get(i); System.out.println("ID: " + bulkresponse.getRequestID()); - /* - * if (bulkresponse.getSignedPDF() != null) { - * FileOutputStream fos2 = new FileOutputStream( - * "/home/afitzek/simple_request_obj_signed_"+ i +".pdf"); - * fos2.write(bulkresponse.getSignedPDF()); fos2.close(); } - */ + if (bulkresponse.getError() != null) { System.out.println("ERROR: " + bulkresponse.getError()); } else { @@ -90,7 +91,7 @@ public class SimpleTest { } } } - + */ System.out.println("Done!"); } catch (Throwable e) { e.printStackTrace(); -- cgit v1.2.3