summaryrefslogtreecommitdiff
path: root/npc
diff options
context:
space:
mode:
Diffstat (limited to 'npc')
-rw-r--r--npc/dev/test.txt10
1 files changed, 10 insertions, 0 deletions
diff --git a/npc/dev/test.txt b/npc/dev/test.txt
index c2f07ab2f..2822ee65c 100644
--- a/npc/dev/test.txt
+++ b/npc/dev/test.txt
@@ -775,6 +775,16 @@ function script HerculesSelfTestHelper {
callsub(OnCheck, "Getdatatype (getarg integer value)", callsub(OnTestGetdatatype, 5), DATATYPE_INT);
callsub(OnCheck, "Getdatatype (getarg string)", callsub(OnTestGetdatatype, "foo"), DATATYPE_STR | DATATYPE_CONST);
+ callsub(OnCheck, "data_to_string (NIL)", data_to_string(), "");
+ callsub(OnCheck, "data_to_string (empty string)", data_to_string(""), "");
+ callsub(OnCheck, "data_to_string (string)", data_to_string("foo"), "foo");
+ callsub(OnCheck, "data_to_string (integer)", data_to_string(5), "5");
+ callsub(OnCheck, "data_to_string (parameter)", data_to_string(Hp), "Hp");
+ callsub(OnCheck, "data_to_string (constant)", data_to_string(DATATYPE_CONST), "DATATYPE_CONST");
+ callsub(OnCheck, "data_to_string (label)", data_to_string(OnTestGetdatatype), "OnTestGetdatatype");
+ callsub(OnCheck, "data_to_string (string variable)", data_to_string(.@x$), ".@x$");
+ callsub(OnCheck, "data_to_string (integer variable)", data_to_string(.@x), ".@x");
+
if (.errors) {
debugmes "Script engine self-test [ \033[0;31mFAILED\033[0m ]";
debugmes "**** The test was completed with " + .errors + " errors. ****";