summaryrefslogtreecommitdiff
path: root/ext/gd/tests/imagestringup_basic.phpt
diff options
context:
space:
mode:
authorChristoph M. Becker <cmbecker69@gmx.de>2016-08-17 17:59:33 +0200
committerChristoph M. Becker <cmbecker69@gmx.de>2016-08-17 17:59:33 +0200
commita3159d29bb24d5c946c14b7aa33e96bebcd56e59 (patch)
tree771b0da28d52572069c9f964b371f1c33748beeb /ext/gd/tests/imagestringup_basic.phpt
parent48198e4c257825ab89ee027bff5a93fc2cd59601 (diff)
downloadphp-git-a3159d29bb24d5c946c14b7aa33e96bebcd56e59.tar.gz
Make tests a little more resilient
PNG allows identical images to be stored differently what makes nearly all tests checking the MD5 hash of the PNG representation fail with external libgd. For now, we use the GD format instead, which doesn't allow for such differences. Of course, this md5() checking should be replaced by a image diffing feature in the long run.
Diffstat (limited to 'ext/gd/tests/imagestringup_basic.phpt')
-rw-r--r--ext/gd/tests/imagestringup_basic.phpt4
1 files changed, 2 insertions, 2 deletions
diff --git a/ext/gd/tests/imagestringup_basic.phpt b/ext/gd/tests/imagestringup_basic.phpt
index 0c748b6aa9..144dfc0d8d 100644
--- a/ext/gd/tests/imagestringup_basic.phpt
+++ b/ext/gd/tests/imagestringup_basic.phpt
@@ -15,11 +15,11 @@ $white = imagecolorallocate($image, 255,255,255);
$result = imagestringup($image, 1, 5, 25, 'Str', $white);
ob_start();
-imagepng($image, null, 9);
+imagegd($image);
$img = ob_get_contents();
ob_end_clean();
echo md5(base64_encode($img));
?>
--EXPECT--
-7c28016adcf620b772af2a8655b87bd2
+7c55836800702bdd43b4c25d8ebcfcd0