summaryrefslogtreecommitdiff
path: root/php/test
diff options
context:
space:
mode:
authorDwayne Boone <dwayne@zeroc.com>2015-03-04 12:42:00 -0330
committerDwayne Boone <dwayne@zeroc.com>2015-03-04 12:42:00 -0330
commit17eecd44fddb363b81a404ea510eb58375a37a38 (patch)
treeacaf6d3a4fbb7e31a7ff93d926afc5e45e3823d1 /php/test
parentFixed LD_LIBRARY_PATH settings in gradle plug-in (diff)
downloadice-17eecd44fddb363b81a404ea510eb58375a37a38.tar.bz2
ice-17eecd44fddb363b81a404ea510eb58375a37a38.tar.xz
ice-17eecd44fddb363b81a404ea510eb58375a37a38.zip
ICE-6306 Added float range checks to php/rb/py
Diffstat (limited to 'php/test')
-rw-r--r--php/test/Ice/operations/Client.php23
1 files changed, 22 insertions, 1 deletions
diff --git a/php/test/Ice/operations/Client.php b/php/test/Ice/operations/Client.php
index 85e4fa5bf7f..f5579a24a37 100644
--- a/php/test/Ice/operations/Client.php
+++ b/php/test/Ice/operations/Client.php
@@ -182,6 +182,27 @@ function twoways($communicator, $p)
catch(InvalidArgumentException $ex)
{
}
+
+ $r = $p->opFloatDouble(3.402823466E38, 0.0, $f, $d);
+ $r = $p->opFloatDouble(-3.402823466E38, 0.0, $f, $d);
+
+ try
+ {
+ $r = $p->opFloatDouble(3.402823466E38*2, 0.0, $f, $d);
+ test(false);
+ }
+ catch(InvalidArgumentException $ex)
+ {
+ }
+
+ try
+ {
+ $r = $p->opFloatDouble(-3.402823466E38*2, 0.0, $f, $d);
+ test(false);
+ }
+ catch(InvalidArgumentException $ex)
+ {
+ }
}
{
@@ -898,7 +919,7 @@ function twoways($communicator, $p)
{
$p->opNonmutating();
}
-
+
test($p->opByte1(0xFF) == 0xFF);
test($p->opShort1(0x7FFF) == 0x7FFF);
test($p->opInt1(0x7FFFFFFF) == 0x7FFFFFFF);