diff options
author | Rüdiger Timm <rt@openoffice.org> | 2004-09-20 13:49:46 +0000 |
---|---|---|
committer | Rüdiger Timm <rt@openoffice.org> | 2004-09-20 13:49:46 +0000 |
commit | 03a7dbe95a4e2a48945bff27cc337795e714d917 (patch) | |
tree | 86dc1ba65e197222a261fc5fc24b640162b9a212 /testtools | |
parent | cd7649ae7f9f9805971178c3b1fc42ef588eddf0 (diff) |
INTEGRATION: CWS jl12 (1.3.8); FILE MERGED
2004/09/08 09:07:23 jl 1.3.8.1: #i33445#
Diffstat (limited to 'testtools')
-rw-r--r-- | testtools/source/bridgetest/cli/cli_cs_bridgetest.cs | 31 |
1 files changed, 18 insertions, 13 deletions
diff --git a/testtools/source/bridgetest/cli/cli_cs_bridgetest.cs b/testtools/source/bridgetest/cli/cli_cs_bridgetest.cs index 84063f9b8949..9356770336f7 100644 --- a/testtools/source/bridgetest/cli/cli_cs_bridgetest.cs +++ b/testtools/source/bridgetest/cli/cli_cs_bridgetest.cs @@ -2,9 +2,9 @@ * * $RCSfile: cli_cs_bridgetest.cs,v $ * - * $Revision: 1.4 $ + * $Revision: 1.5 $ * - * last change: $Author: obo $ $Date: 2004-09-15 10:13:07 $ + * last change: $Author: rt $ $Date: 2004-09-20 14:49:46 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -598,23 +598,22 @@ static bool performTest(XBridgeTest xLBT) bRet &= check(false, "transportPolySequence"); } - try { //When the test object is a cli object then them member is null //otherwise the bridge has provided a default value. - TestPolyStruct s = (TestPolyStruct) xLBT.getNullPolyLong(); + TestPolyStruct s = xLBT.getNullPolyLong(); if (s.member != null) bRet &= check(((int) s.member) == 0, "getNullPolyLong"); - s = (TestPolyStruct) xLBT.getNullPolyString(); + s = xLBT.getNullPolyString(); if (s.member != null) bRet &= check(((string) s.member).Length == 0, "getNullPolyString"); - s = (TestPolyStruct) xLBT.getNullPolyType(); + s = xLBT.getNullPolyType(); if (s.member != null) bRet &= check(((Type) s.member) == typeof(void), "getNullPolyType"); - s = (TestPolyStruct) xLBT.getNullPolyAny(); + s = xLBT.getNullPolyAny(); if (s.member != null) { Any nullAny = (Any) s.member; @@ -622,21 +621,24 @@ static bool performTest(XBridgeTest xLBT) bRet &= check(nullAny.Type == typeof(void), "getNullPolyAny"); } - s = (TestPolyStruct) xLBT.getNullPolySequence(); + s = xLBT.getNullPolySequence(); if (s.member != null) bRet &= check(((bool[]) s.member).Length == 0, "getNullPolySequence"); - s = (TestPolyStruct) xLBT.getNullPolyEnum(); + s = xLBT.getNullPolyEnum(); if (s.member != null) bRet &= check(((TestEnum) s.member) == TestEnum.TEST, "getNullPolyEnum"); - s = (TestPolyStruct) xLBT.getNullPolyStruct(); + s = xLBT.getNullPolyStruct(); if (s.member != null) bRet &= check(((TestStruct) s.member).member == 0, "getNullPolyStruct"); - s = (TestPolyStruct) xLBT.getNullPolyInterface(); + s = xLBT.getNullPolyInterface(); bRet &= check(s.member == null, "getNullPolyInterface"); + s = xLBT.getNullPolyBadEnum(); + bRet &= check(((TestBadEnum)s.member) == TestBadEnum.M, "getNullPolyBadEnum"); + } catch(InvalidCastException) { bRet &= check(false, "getNullPolyXXX, InvalidCastException"); @@ -1020,6 +1022,8 @@ static bool raiseException(XBridgeTest xLBT ) public int run( String [] args ) { + Debug.AutoFlush = true; + try { if (args.Length < 1) @@ -1031,8 +1035,9 @@ static bool raiseException(XBridgeTest xLBT ) m_xContext.getServiceManager().createInstanceWithContext( args[ 0 ], m_xContext ); - Console.WriteLine( - "cli target bridgetest obj: {0}", test_obj.ToString() ); + Debug.WriteLine( + "Calling object: {0}", test_obj.ToString() ); + XBridgeTest xTest = (XBridgeTest) test_obj ; perform_test( xTest ); Console.WriteLine( "\n### cli_uno C# bridgetest succeeded." ); |