From 1fc8ca6257292d60b34a17983696047b24283225 Mon Sep 17 00:00:00 2001 From: Jan Jezabek Date: Sun, 17 Aug 2008 19:15:01 +0000 Subject: Added apply_strings run-test. git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/branches/gsoc2008-jezabek@10773 626c5289-ae23-0410-ae9c-e8d60b6d4f22 --- Examples/test-suite/com/apply_strings_runme.vbs | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 Examples/test-suite/com/apply_strings_runme.vbs diff --git a/Examples/test-suite/com/apply_strings_runme.vbs b/Examples/test-suite/com/apply_strings_runme.vbs new file mode 100644 index 000000000..6f737031f --- /dev/null +++ b/Examples/test-suite/com/apply_strings_runme.vbs @@ -0,0 +1,24 @@ +Dim apply_strings, TEST_MESSAGE + +Set apply_strings = CreateObject("apply_strings.apply_strings") +TEST_MESSAGE = "A message from target language to the C++ world and back again." + +If apply_strings.UCharFunction(TEST_MESSAGE) <> TEST_MESSAGE Then + WScript.Echo "UCharFunction failed" + WScript.Quit 1 +End If + +If apply_strings.SCharFunction(TEST_MESSAGE) <> TEST_MESSAGE Then + WScript.Echo "SCharFunction failed" + WScript.Quit 1 +End If + +Dim pChar + +Rem Will fail currently +Set pChar = apply_strings.CharFunction(null) +If pChar <> null Then + WScript.Echo "CharFunction failed" + WScript.Quit 1 +End If + -- cgit v1.2.1