We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 7639a2c commit 9aa1522Copy full SHA for 9aa1522
1 file changed
tests/issue137.phpt
@@ -0,0 +1,22 @@
1
+--TEST--
2
+Issue #137 (DateTime(Immutable) serialization doesn't work with php 7.4)
3
+--SKIPIF--
4
+<?php
5
+if (!extension_loaded("msgpack")) {
6
+ echo "skip";
7
+}
8
+--FILE--
9
10
+var_dump(msgpack_unpack(msgpack_pack(new DatetimeImmutable)));
11
+?>
12
+OK
13
+--EXPECTF--
14
+object(DateTimeImmutable)#%d (3) {
15
+ ["date"]=>
16
+ string(26) "%d-%d-%d %d:%d:%f"
17
+ ["timezone_type"]=>
18
+ int(%d)
19
+ ["timezone"]=>
20
+ string(%d) "%s"
21
22
0 commit comments