summaryrefslogtreecommitdiff
path: root/ext/standard/tests/strings/chr_basic.phpt
diff options
context:
space:
mode:
Diffstat (limited to 'ext/standard/tests/strings/chr_basic.phpt')
-rw-r--r--ext/standard/tests/strings/chr_basic.phpt23
1 files changed, 23 insertions, 0 deletions
diff --git a/ext/standard/tests/strings/chr_basic.phpt b/ext/standard/tests/strings/chr_basic.phpt
new file mode 100644
index 0000000..378b402
--- /dev/null
+++ b/ext/standard/tests/strings/chr_basic.phpt
@@ -0,0 +1,23 @@
+--TEST--
+Test chr() function : basic functionality
+--FILE--
+<?php
+
+/* Prototype : string chr ( int $ascii )
+ * Description: Return a specific character
+ * Source code: ext/standard/string.c
+*/
+
+echo "*** Testing chr() : basic functionality ***\n";
+
+echo chr(72). chr(101) . chr(108) . chr(108). chr(111); // Hello
+echo chr(10); // "\n"
+echo "World";
+echo "\n";
+?>
+===DONE===
+--EXPECTF--
+*** Testing chr() : basic functionality ***
+Hello
+World
+===DONE===