public void TestMostSpecTypeSrvWithServerSideIf() { string objToString = m_orb.object_to_string(m_testServiceInternalIf); Ch.Elca.Iiop.CorbaObjRef.Ior forObj = new Ch.Elca.Iiop.CorbaObjRef.Ior(objToString); Assert.AreEqual("IDL:Internal/TestSimpleServiceInternal:1.0", forObj.TypID); }
public void TestSSLComponent() { IOrbServices orb = OrbServices.GetSingleton(); string iorString = orb.object_to_string(m_newTestService); Ior ior = new Ior(iorString); Assert.IsTrue(ior.Profiles.Length > 0, "nr of profiles"); IIorProfile profile = ior.Profiles[0]; omg.org.IOP.CodecFactory codecFactory = (omg.org.IOP.CodecFactory) orb.resolve_initial_references("CodecFactory"); object sslData = profile.TaggedComponents.GetComponentData(20, codecFactory.create_codec(new omg.org.IOP.Encoding(omg.org.IOP.ENCODING_CDR_ENCAPS.ConstVal, 1, 2)), SSLComponentData.TypeCode); Assert.NotNull(sslData); Assert.AreEqual((int)8087, ((SSLComponentData)sslData).GetPort()); }
public void TestCodeSetComponent() { IOrbServices orb = OrbServices.GetSingleton(); string iorString = orb.object_to_string(m_newTestService); Ior ior = new Ior(iorString); Assert.IsTrue(ior.Profiles.Length > 0, "nr of profiles"); IIorProfile profile = ior.Profiles[0]; omg.org.IOP.CodecFactory codecFactory = (omg.org.IOP.CodecFactory) orb.resolve_initial_references("CodecFactory"); object codeset = profile.TaggedComponents.GetComponentData(1, codecFactory.create_codec(new omg.org.IOP.Encoding(omg.org.IOP.ENCODING_CDR_ENCAPS.ConstVal, 1, 2)), CodeSetComponentData.TypeCode); Assert.NotNull(codeset); Assert.AreEqual((int)CharSet.UTF8, ((CodeSetComponentData)codeset).NativeCharSet); Assert.AreEqual((int)WCharSet.UTF16, ((CodeSetComponentData)codeset).NativeWCharSet); }