com php-src: PHP_INT_MIN and _MAX tests: tests/ lang/constants/PHP_INT_32bit.phpt tests/lang/consta nts/PHP_INT_64bit.phpt

From: Date: Fri, 01 Aug 2014 16:01:17 +0000
Subject: com php-src: PHP_INT_MIN and _MAX tests: tests/ lang/constants/PHP_INT_32bit.phpt tests/lang/consta nts/PHP_INT_64bit.phpt
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-79703@lists.php.net to get a copy of this message
Commit: fe894c2154e6b013f0d0b29ca660ad719fd1affe Author: Andrea Faulds <ajf@ajf.me> Fri, 1 Aug 2014 17:01:17 +0100 Parents: a2bbc6f985570a031c38c1c1205bc78786e83518 Branches: master Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=fe894c2154e6b013f0d0b29ca660ad719fd1affe Log: PHP_INT_MIN and _MAX tests Changed paths: A tests/lang/constants/PHP_INT_32bit.phpt A tests/lang/constants/PHP_INT_64bit.phpt Diff: diff --git a/tests/lang/constants/PHP_INT_32bit.phpt b/tests/lang/constants/PHP_INT_32bit.phpt new file mode 100644 index 0000000..0c85d97 --- /dev/null +++ b/tests/lang/constants/PHP_INT_32bit.phpt @@ -0,0 +1,17 @@ +--TEST-- +Test PHP_INT_MIN, PHP_INT_MAX and PHP_INT_SIZE (32-bit) +--SKIPIF-- +<?php if (PHP_INT_SIZE !== 4) + die("skip this test is for 32-bit platforms only"); ?> +--FILE-- +<?php + +var_dump(PHP_INT_MIN); +var_dump(PHP_INT_MAX); +var_dump(PHP_INT_SIZE); + +?> +--EXPECT-- +int(-2147483648) +int(2147483647) +int(4) \ No newline at end of file diff --git a/tests/lang/constants/PHP_INT_64bit.phpt b/tests/lang/constants/PHP_INT_64bit.phpt new file mode 100644 index 0000000..4b7da3a --- /dev/null +++ b/tests/lang/constants/PHP_INT_64bit.phpt @@ -0,0 +1,17 @@ +--TEST-- +Test PHP_INT_MIN, PHP_INT_MAX and PHP_INT_SIZE (64-bit) +--SKIPIF-- +<?php if (PHP_INT_SIZE !== 8) + die("skip this test is for 64-bit platforms only"); ?> +--FILE-- +<?php + +var_dump(PHP_INT_MIN); +var_dump(PHP_INT_MAX); +var_dump(PHP_INT_SIZE); + +?> +--EXPECT-- +int(-9223372036854775808) +int(9223372036854775807) +int(8) \ No newline at end of file

« previous php.cvs (#79703) next »