summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Examples/test-suite/com/apply_strings_runme.vbs24
1 files changed, 24 insertions, 0 deletions
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
+