summaryrefslogtreecommitdiff
path: root/tests/cpp/include/variables/021-HashMember-3.h
diff options
context:
space:
mode:
Diffstat (limited to 'tests/cpp/include/variables/021-HashMember-3.h')
-rw-r--r--tests/cpp/include/variables/021-HashMember-3.h41
1 files changed, 41 insertions, 0 deletions
diff --git a/tests/cpp/include/variables/021-HashMember-3.h b/tests/cpp/include/variables/021-HashMember-3.h
new file mode 100644
index 0000000..f7c0914
--- /dev/null
+++ b/tests/cpp/include/variables/021-HashMember-3.h
@@ -0,0 +1,41 @@
+/**
+ *
+ * Test variables
+ * 019-HashMember-3.phpt
+ * Test HashMember
+ *
+ */
+
+
+
+
+/**
+ * Set up namespace
+ */
+namespace TestVariables {
+
+ /**
+ * This function returns complex array
+ */
+ Php::Value test_HashMember_3()
+ {
+
+ Php::Value r, tmp(Php::Type::Array);
+ //Php::Value tmp;
+
+ tmp.set("key2", "val1-2");
+ r.set("key1", tmp);
+ r.get("key1").set("key3", "val1-3");
+
+ // expect to receive the same as when recording:
+ //r["key1"]["key2"] = "val1-2";
+ //r["key1"]["key3"] = "val1-3";
+
+ return r;
+ }
+
+/**
+ * End of namespace
+ */
+}
+