<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/php-git.git/ext/gd/tests/libgd00100.phpt, branch php-7.0.12</title>
<subtitle>git.php.net: repository/php-src.git
</subtitle>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/php-git.git/'/>
<entry>
<title>A picture is worth a thousand message digests</title>
<updated>2016-09-11T10:56:53+00:00</updated>
<author>
<name>Christoph M. Becker</name>
<email>cmbecker69@gmx.de</email>
</author>
<published>2016-06-19T12:29:27+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/php-git.git/commit/?id=dc09f309335cf8df7d39adc03580ac8d4f0c78f5'/>
<id>dc09f309335cf8df7d39adc03580ac8d4f0c78f5</id>
<content type='text'>
The bundled GD test suites makes heavy use of md5() to verify the result
of drawing operations. This leads to fragile tests (even a slight change
in a PNG header would cause failure, and of course there is the
possibility of collisions), and even worse, eventual test failures are
rather unrevealing.

Therefore we replace all md5() verification with a simplistic
test_image_equals_file(), which is basically a simplified port of libgd's
gdTestImageCompareToFile(), adapted to the needs of PHPTs.

In the long run better tests helpers should be introduced (see also
&lt;http://news.php.net/php.internals/94081&gt;), but for now this solution
is preferable over the former.

(cherry picked from commit 24f9e96792518ec2a75f26b1eb2471dd7694f2b7)
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The bundled GD test suites makes heavy use of md5() to verify the result
of drawing operations. This leads to fragile tests (even a slight change
in a PNG header would cause failure, and of course there is the
possibility of collisions), and even worse, eventual test failures are
rather unrevealing.

Therefore we replace all md5() verification with a simplistic
test_image_equals_file(), which is basically a simplified port of libgd's
gdTestImageCompareToFile(), adapted to the needs of PHPTs.

In the long run better tests helpers should be introduced (see also
&lt;http://news.php.net/php.internals/94081&gt;), but for now this solution
is preferable over the former.

(cherry picked from commit 24f9e96792518ec2a75f26b1eb2471dd7694f2b7)
</pre>
</div>
</content>
</entry>
<entry>
<title>Make tests a little more resilient</title>
<updated>2016-08-17T15:59:33+00:00</updated>
<author>
<name>Christoph M. Becker</name>
<email>cmbecker69@gmx.de</email>
</author>
<published>2016-08-17T15:59:33+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/php-git.git/commit/?id=a3159d29bb24d5c946c14b7aa33e96bebcd56e59'/>
<id>a3159d29bb24d5c946c14b7aa33e96bebcd56e59</id>
<content type='text'>
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.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
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.
</pre>
</div>
</content>
</entry>
<entry>
<title>fix libgd FS100 (spurious horizontal line drawn by gdImageFilledPolygon)</title>
<updated>2010-01-20T09:39:06+00:00</updated>
<author>
<name>Takeshi Abe</name>
<email>tabe@php.net</email>
</author>
<published>2010-01-20T09:39:06+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/php-git.git/commit/?id=e03c60f06419ce07b56e082a549fd474290fb484'/>
<id>e03c60f06419ce07b56e082a549fd474290fb484</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
</feed>
