diff options
Diffstat (limited to 'ext/gd/tests/bug42434.phpt')
| -rw-r--r-- | ext/gd/tests/bug42434.phpt | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/ext/gd/tests/bug42434.phpt b/ext/gd/tests/bug42434.phpt new file mode 100644 index 0000000..bc0790e --- /dev/null +++ b/ext/gd/tests/bug42434.phpt @@ -0,0 +1,27 @@ +--TEST--
+Bug #42434 (ImageLine w/ antialias = 1px shorter)
+--SKIPIF--
+<?php
+if (!extension_loaded('gd')) {
+ die('skip gd extension not available');
+}
+if (!GD_BUNDLED) die("skip requires bundled GD library\n");
+?>
+--FILE--
+<?php
+$im = imagecreatetruecolor(10, 2);
+imagefilledrectangle($im, 0, 0, 10, 2, 0xFFFFFF);
+
+imageantialias($im, true);
+imageline($im, 0, 0, 10, 0, 0x000000);
+
+if (imagecolorat($im, 9, 0) == 0x000000) {
+ echo 'DONE';
+} else {
+ echo 'Bugged';
+}
+
+imagedestroy($im);
+?>
+--EXPECTF--
+DONE
\ No newline at end of file |
