Examples of SaveBusiness


Examples of org.uddi.api_v3.SaveBusiness

                }
        }

        @Test()
        public void JUDDI_712_SaveBusinessProjectionNoServiceKey3WithSignature() throws CertificateException {
                SaveBusiness sb = new SaveBusiness();
                sb.setAuthInfo(authInfoJoe);
                BusinessEntity be = new BusinessEntity();
                Name n = new Name();
                n.setValue("JUDDI_712_SaveBusinessProjectionNoServiceKey3WithSignature");
                be.getName().add(n);
                be.setBusinessKey(TckBusiness.JOE_BUSINESS_KEY);

                //service has business but not service key
                BusinessService bs = new BusinessService();
                //bs.setBusinessKey(TckBusiness.JOE_BUSINESS_KEY);
                bs.setServiceKey(TckBusinessService.JOE_SERVICE_KEY);
                bs.getName().add(new Name("Joe's bs", null));
                be.setBusinessServices(new BusinessServices());
                be.getBusinessServices().getBusinessService().add(bs);

                DigSigUtil ds = GetDigSig();
                be = ds.signUddiEntity(be);
                sb.getBusinessEntity().add(be);
                try {
                        BusinessDetail saveBusiness = publicationJoe.saveBusiness(sb);
                        Assert.fail("unexpected success");
                } catch (Exception ex) {
                        logger.info("Expected failure: " + ex.getMessage());
View Full Code Here

Examples of org.uddi.api_v3.SaveBusiness

                }
        }

        @Test()
        public void JUDDI_712_SaveServiceProjectionNoServiceKey3WithSignature() throws CertificateException {
                SaveBusiness sb = new SaveBusiness();
                sb.setAuthInfo(authInfoJoe);
                BusinessEntity be = new BusinessEntity();
                Name n = new Name();
                n.setValue("JUDDI_712_SaveServiceProjectionNoServiceKey3WithSignature");
                be.getName().add(n);
                be.setBusinessKey(TckBusiness.JOE_BUSINESS_KEY);

                BusinessService bs = new BusinessService();
                bs.setBusinessKey(null);
                bs.setServiceKey(null);
                bs.getName().add(new Name("Joe's bs", null));
                DigSigUtil ds = GetDigSig();
                bs = ds.signUddiEntity(bs);

                be.setBusinessServices(new BusinessServices());
                be.getBusinessServices().getBusinessService().add(bs);

                sb.getBusinessEntity().add(be);
                try {
                        BusinessDetail saveBusiness = publicationJoe.saveBusiness(sb);
                        Assert.fail("unexpected success");
                } catch (Exception ex) {
                        logger.info("Expected failure: " + ex.getMessage());
View Full Code Here

Examples of org.uddi.api_v3.SaveBusiness

                }
        }

        @Test()
        public void JUDDI_712_SaveServiceProjectionNoServiceKey1WithSignature() throws CertificateException {
                SaveBusiness sb = new SaveBusiness();
                sb.setAuthInfo(authInfoJoe);
                BusinessEntity be = new BusinessEntity();
                Name n = new Name();
                n.setValue("JUDDI_712_SaveServiceProjectionNoServiceKey1WithSignature");
                be.getName().add(n);
                be.setBusinessKey(TckBusiness.JOE_BUSINESS_KEY);

                BusinessService bs = new BusinessService();
                bs.setBusinessKey(null);
                bs.setServiceKey(TckBusinessService.JOE_SERVICE_KEY);
                bs.getName().add(new Name("Joe's bs", null));
                DigSigUtil ds = GetDigSig();
                bs = ds.signUddiEntity(bs);

                be.setBusinessServices(new BusinessServices());
                be.getBusinessServices().getBusinessService().add(bs);

                sb.getBusinessEntity().add(be);
                try {
                        BusinessDetail saveBusiness = publicationJoe.saveBusiness(sb);
                        Assert.fail("unexpected success");
                } catch (Exception ex) {
                        logger.info("Expected failure: " + ex.getMessage());
View Full Code Here

Examples of org.uddi.api_v3.SaveBusiness

                }
        }

        @Test()
        public void JUDDI_712_SaveServiceProjectionNoServiceKey2WithSignature() throws CertificateException {
                SaveBusiness sb = new SaveBusiness();
                sb.setAuthInfo(authInfoJoe);
                BusinessEntity be = new BusinessEntity();
                Name n = new Name();
                n.setValue("JUDDI_712_SaveServiceProjectionNoServiceKey2WithSignature");
                be.getName().add(n);
                be.setBusinessKey(TckBusiness.JOE_BUSINESS_KEY);

                BusinessService bs = new BusinessService();
                bs.setBusinessKey(TckBusiness.JOE_BUSINESS_KEY);
                bs.setServiceKey(null);
                bs.getName().add(new Name("Joe's bs", null));
                DigSigUtil ds = GetDigSig();
                bs = ds.signUddiEntity(bs);

                be.setBusinessServices(new BusinessServices());
                be.getBusinessServices().getBusinessService().add(bs);

                sb.getBusinessEntity().add(be);
                try {
                        BusinessDetail saveBusiness = publicationJoe.saveBusiness(sb);
                        Assert.fail("unexpected success");
                } catch (Exception ex) {
                        logger.info("Expected failure: " + ex.getMessage());
View Full Code Here

Examples of org.uddi.api_v3.SaveBusiness

                        logger.info("Expected failure: " + ex.getMessage());
                }
        }

        public void JUDDI_712_SaveBusinessNoneDefined() throws Exception {
                SaveBusiness sb = new SaveBusiness();
                sb.setAuthInfo(authInfoJoe);
                BusinessEntity be = new BusinessEntity();
                Name n = new Name();
                n.setValue("JUDDI_712_SaveServiceWithSignature");
                be.getName().add(n);
                be.setBusinessKey(TckBusiness.JOE_BUSINESS_KEY);
View Full Code Here

Examples of org.uddi.api_v3.SaveBusiness

                }
        }

        @Test()
        public void JUDDI_712_SaveServiceWithSignature() throws CertificateException {
                SaveBusiness sb = new SaveBusiness();
                sb.setAuthInfo(authInfoJoe);
                BusinessEntity be = new BusinessEntity();
                Name n = new Name();
                n.setValue("JUDDI_712_SaveServiceWithSignature");
                be.getName().add(n);
                be.setBusinessKey(TckBusiness.JOE_BUSINESS_KEY);
                sb.getBusinessEntity().add(be);
                try {
                        BusinessDetail saveBusiness = publicationJoe.saveBusiness(sb);
                } catch (Exception ex) {
                        logger.info("UnExpected failure: ", ex);
                        Assert.fail();
                }

                SaveService ss = new SaveService();
                ss.setAuthInfo(authInfoJoe);
                BusinessService bs = new BusinessService();
                bs.setBusinessKey(TckBusiness.JOE_BUSINESS_KEY);
                bs.setServiceKey(null);
                bs.getName().add(new Name("Joe's bs", null));
                DigSigUtil ds = GetDigSig();
                bs = ds.signUddiEntity(bs);

                be.setBusinessServices(new BusinessServices());
                be.getBusinessServices().getBusinessService().add(bs);

                sb.getBusinessEntity().add(be);
                try {
                        publicationJoe.saveService(ss);
                        Assert.fail("unexpected success");
                } catch (Exception ex) {
                        logger.info("Expected failure: " + ex.getMessage());
View Full Code Here

Examples of org.uddi.api_v3.SaveBusiness

                }
        }

        @Test()
        public void JUDDI_712_SaveService1WithSignature() throws CertificateException {
                SaveBusiness sb = new SaveBusiness();
                sb.setAuthInfo(authInfoJoe);
                BusinessEntity be = new BusinessEntity();
                Name n = new Name();
                n.setValue("JUDDI_712_SaveService1WithSignature");
                be.getName().add(n);
                be.setBusinessKey(TckBusiness.JOE_BUSINESS_KEY);
                sb.getBusinessEntity().add(be);
                BusinessDetail saveBusiness = null;
                try {
                        saveBusiness = publicationJoe.saveBusiness(sb);
                } catch (Exception ex) {
                        logger.info("UnExpected failure: ", ex);
                        Assert.fail();
                }

                SaveService ss = new SaveService();
                ss.setAuthInfo(authInfoJoe);
                BusinessService bs = new BusinessService();
                bs.setBusinessKey(TckBusiness.JOE_BUSINESS_KEY);
                bs.setServiceKey(TckBusinessService.JOE_SERVICE_KEY);
                bs.setBindingTemplates(new BindingTemplates());
                BindingTemplate bt = new BindingTemplate();
                bt.setBindingKey(null);
                bt.setServiceKey(null);
                bt.setAccessPoint(new AccessPoint("http://localhost", "wsdl"));
                bs.getBindingTemplates().getBindingTemplate().add(bt);
                bs.getName().add(new Name("Joe's bs", null));
                DigSigUtil ds = GetDigSig();
                bs = ds.signUddiEntity(bs);

                be.setBusinessServices(new BusinessServices());
                be.getBusinessServices().getBusinessService().add(bs);

                sb.getBusinessEntity().add(be);
                try {
                        publicationJoe.saveService(ss);
                        Assert.fail("unexpected success");
                } catch (Exception ex) {
                        logger.info("Expected failure: " + ex.getMessage());
View Full Code Here

Examples of org.uddi.api_v3.SaveBusiness

        public static SaveBusiness MapSaveBusiness(org.uddi.api_v2.SaveBusiness body) {
                if (body == null) {
                        return null;
                }
                SaveBusiness r = new SaveBusiness();
                r.setAuthInfo(body.getAuthInfo());
                for (int i = 0; i < body.getBusinessEntity().size(); i++) {
                        r.getBusinessEntity().add(MapBusiness(body.getBusinessEntity().get(i)));
                }
                return r;
        }
View Full Code Here

Examples of org.uddi.api_v3.SaveBusiness

                }
        }

        @Test()
        public void JUDDI_712_SaveService2WithSignature() throws CertificateException {
                SaveBusiness sb = new SaveBusiness();
                sb.setAuthInfo(authInfoJoe);
                BusinessEntity be = new BusinessEntity();
                Name n = new Name();
                n.setValue("JUDDI_712_SaveService2WithSignature");
                be.getName().add(n);
                be.setBusinessKey(TckBusiness.JOE_BUSINESS_KEY);
                sb.getBusinessEntity().add(be);
                BusinessDetail saveBusiness = null;
                try {

                        saveBusiness = publicationJoe.saveBusiness(sb);
                } catch (Exception ex) {
                        logger.info("UnExpected failure: ", ex);
                        Assert.fail();
                }

                SaveService ss = new SaveService();
                ss.setAuthInfo(authInfoJoe);
                BusinessService bs = new BusinessService();
                bs.setBusinessKey(TckBusiness.JOE_BUSINESS_KEY);
                bs.setServiceKey(TckBusinessService.JOE_SERVICE_KEY);
                bs.setBindingTemplates(new BindingTemplates());
                BindingTemplate bt = new BindingTemplate();
                bt.setBindingKey(null);
                bt.setServiceKey(TckBusinessService.JOE_SERVICE_KEY);
                bt.setAccessPoint(new AccessPoint("http://localhost", "wsdl"));
                bs.getBindingTemplates().getBindingTemplate().add(bt);
                bs.getName().add(new Name("Joe's bs", null));
                DigSigUtil ds = GetDigSig();
                bs = ds.signUddiEntity(bs);

                be.setBusinessServices(new BusinessServices());
                be.getBusinessServices().getBusinessService().add(bs);

                sb.getBusinessEntity().add(be);
                try {
                        publicationJoe.saveService(ss);
                        Assert.fail("unexpected success");
                } catch (Exception ex) {
                        logger.info("Expected failure: " + ex.getMessage());
View Full Code Here

Examples of org.uddi.api_v3.SaveBusiness

                }
        }

        @Test()
        public void JUDDI_712_SaveService3WithSignature() throws CertificateException {
                SaveBusiness sb = new SaveBusiness();
                sb.setAuthInfo(authInfoJoe);
                BusinessEntity be = new BusinessEntity();
                Name n = new Name();
                n.setValue("JUDDI_712_SaveService3WithSignature");
                be.getName().add(n);
                be.setBusinessKey(TckBusiness.JOE_BUSINESS_KEY);
                sb.getBusinessEntity().add(be);
                BusinessDetail saveBusiness = null;
                try {
                        saveBusiness = publicationJoe.saveBusiness(sb);
                } catch (Exception ex) {
                        logger.info("UnExpected failure: ", ex);
                        Assert.fail();
                }

                SaveService ss = new SaveService();
                ss.setAuthInfo(authInfoJoe);
                BusinessService bs = new BusinessService();
                bs.setBusinessKey(TckBusiness.JOE_BUSINESS_KEY);
                bs.setServiceKey(TckBusinessService.JOE_SERVICE_KEY);
                bs.setBindingTemplates(new BindingTemplates());
                BindingTemplate bt = new BindingTemplate();
                bt.setBindingKey(TckBusinessService.JOE_BINDING_KEY_1);
                bt.setServiceKey(null);
                bt.setAccessPoint(new AccessPoint("http://localhost", "wsdl"));
                bs.getBindingTemplates().getBindingTemplate().add(bt);
                bs.getName().add(new Name("Joe's bs", null));
                DigSigUtil ds = GetDigSig();
                bs = ds.signUddiEntity(bs);

                be.setBusinessServices(new BusinessServices());
                be.getBusinessServices().getBusinessService().add(bs);

                sb.getBusinessEntity().add(be);
                try {
                        publicationJoe.saveService(ss);
                        Assert.fail("unexpected success");
                } catch (Exception ex) {
                        logger.info("Expected failure: " + ex.getMessage());
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.