10
10
# Author : Sergey Dryabzhinsky #
11
11
# Company : Rusoft Ltd, Russia #
12
12
# Date : Aug 08, 2018 #
13
- # version : 1.0.29 #
13
+ # Version : 1.0.30 #
14
14
# License : Creative Commons CC-BY license #
15
15
# Website : https://github.com/rusoft/php-simple-benchmark-script #
16
16
# Website : https://git.rusoft.ru/open-source/php-simple-benchmark-script #
17
17
# #
18
18
################################################################################
19
19
*/
20
20
21
- $ scriptVersion = '1.0.29 ' ;
21
+ $ scriptVersion = '1.0.30 ' ;
22
22
23
23
// Used in hacks/fixes checks
24
24
$ phpversion = explode ('. ' , PHP_VERSION );
@@ -919,14 +919,21 @@ function test_09_Json_Encode()
919
919
return $ emptyResult ;
920
920
}
921
921
922
+ $ obj = new stdClass ();
923
+ $ obj ->fieldStr = 'value ' ;
924
+ $ obj ->fieldInt = 123456 ;
925
+ $ obj ->fieldFloat = 123.456 ;
926
+ $ obj ->fieldArray = array (123456 );
927
+ $ obj ->fieldNull = null ;
928
+ $ obj ->fieldBool = false ;
922
929
$ data = array (
923
930
$ stringTest ,
924
931
123456 ,
925
932
123.456 ,
926
933
array (123456 ),
927
934
null ,
928
935
false ,
929
- new stdClass () ,
936
+ $ obj ,
930
937
);
931
938
932
939
$ count = $ testsLoopLimits ['09_json_encode ' ];
@@ -948,14 +955,21 @@ function test_10_Json_Decode()
948
955
return $ emptyResult ;
949
956
}
950
957
958
+ $ obj = new stdClass ();
959
+ $ obj ->fieldStr = 'value ' ;
960
+ $ obj ->fieldInt = 123456 ;
961
+ $ obj ->fieldFloat = 123.456 ;
962
+ $ obj ->fieldArray = array (123456 );
963
+ $ obj ->fieldNull = null ;
964
+ $ obj ->fieldBool = false ;
951
965
$ data = array (
952
966
$ stringTest ,
953
967
123456 ,
954
968
123.456 ,
955
969
array (123456 ),
956
970
null ,
957
971
false ,
958
- new stdClass () ,
972
+ $ obj ,
959
973
);
960
974
foreach ($ data as $ key => $ value ) {
961
975
$ data [$ key ] = json_encode ($ value );
@@ -980,14 +994,21 @@ function test_11_Serialize()
980
994
return $ emptyResult ;
981
995
}
982
996
997
+ $ obj = new stdClass ();
998
+ $ obj ->fieldStr = 'value ' ;
999
+ $ obj ->fieldInt = 123456 ;
1000
+ $ obj ->fieldFloat = 123.456 ;
1001
+ $ obj ->fieldArray = array (123456 );
1002
+ $ obj ->fieldNull = null ;
1003
+ $ obj ->fieldBool = false ;
983
1004
$ data = array (
984
1005
$ stringTest ,
985
1006
123456 ,
986
1007
123.456 ,
987
1008
array (123456 ),
988
1009
null ,
989
1010
false ,
990
- new stdClass () ,
1011
+ $ obj ,
991
1012
);
992
1013
993
1014
$ count = $ testsLoopLimits ['11_serialize ' ];
@@ -1009,14 +1030,21 @@ function test_12_Unserialize()
1009
1030
return $ emptyResult ;
1010
1031
}
1011
1032
1033
+ $ obj = new stdClass ();
1034
+ $ obj ->fieldStr = 'value ' ;
1035
+ $ obj ->fieldInt = 123456 ;
1036
+ $ obj ->fieldFloat = 123.456 ;
1037
+ $ obj ->fieldArray = array (123456 );
1038
+ $ obj ->fieldNull = null ;
1039
+ $ obj ->fieldBool = false ;
1012
1040
$ data = array (
1013
1041
$ stringTest ,
1014
1042
123456 ,
1015
1043
123.456 ,
1016
1044
array (123456 ),
1017
1045
null ,
1018
1046
false ,
1019
- new stdClass () ,
1047
+ $ obj ,
1020
1048
);
1021
1049
foreach ($ data as $ key => $ value ) {
1022
1050
$ data [$ key ] = serialize ($ value );
@@ -1240,14 +1268,22 @@ function test_24_XmlRpc_Encode()
1240
1268
return $ emptyResult ;
1241
1269
}
1242
1270
1271
+ $ obj = new stdClass ();
1272
+ $ obj ->fieldStr = 'value ' ;
1273
+ $ obj ->fieldInt = 123456 ;
1274
+ $ obj ->fieldFloat = 123.456 ;
1275
+ $ obj ->fieldArray = array (123456 );
1276
+ $ obj ->fieldNull = null ;
1277
+ $ obj ->fieldBool = false ;
1243
1278
$ data = array (
1244
- $ stringTest ,
1279
+ // XmlRpc don't like html tags (php-7.2 + libxmlrpc-epi)
1280
+ base64_encode ($ stringTest ),
1245
1281
123456 ,
1246
1282
123.456 ,
1247
1283
array (123456 ),
1248
1284
null ,
1249
1285
false ,
1250
- new stdClass () ,
1286
+ $ obj ,
1251
1287
);
1252
1288
1253
1289
$ count = $ testsLoopLimits ['24_xmlrpc_encode ' ];
@@ -1269,14 +1305,22 @@ function test_25_XmlRpc_Decode()
1269
1305
return $ emptyResult ;
1270
1306
}
1271
1307
1308
+ $ obj = new stdClass ();
1309
+ $ obj ->fieldStr = 'value ' ;
1310
+ $ obj ->fieldInt = 123456 ;
1311
+ $ obj ->fieldFloat = 123.456 ;
1312
+ $ obj ->fieldArray = array (123456 );
1313
+ $ obj ->fieldNull = null ;
1314
+ $ obj ->fieldBool = false ;
1272
1315
$ data = array (
1273
- $ stringTest ,
1316
+ // XmlRpc don't like html tags (php-7.2 + libxmlrpc-epi)
1317
+ base64_encode ($ stringTest ),
1274
1318
123456 ,
1275
1319
123.456 ,
1276
1320
array (123456 ),
1277
1321
null ,
1278
1322
false ,
1279
- new stdClass () ,
1323
+ $ obj ,
1280
1324
);
1281
1325
foreach ($ data as $ key => $ value ) {
1282
1326
$ data [$ key ] = xmlrpc_encode ($ value );
0 commit comments