From dc09f309335cf8df7d39adc03580ac8d4f0c78f5 Mon Sep 17 00:00:00 2001 From: "Christoph M. Becker" Date: Sun, 19 Jun 2016 14:29:27 +0200 Subject: A picture is worth a thousand message digests 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 ), but for now this solution is preferable over the former. (cherry picked from commit 24f9e96792518ec2a75f26b1eb2471dd7694f2b7) --- ext/gd/tests/imagearc_basic.png | Bin 0 -> 216 bytes 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 ext/gd/tests/imagearc_basic.png (limited to 'ext/gd/tests/imagearc_basic.png') diff --git a/ext/gd/tests/imagearc_basic.png b/ext/gd/tests/imagearc_basic.png new file mode 100644 index 0000000000..42a4d68988 Binary files /dev/null and b/ext/gd/tests/imagearc_basic.png differ -- cgit v1.2.1