imagefilledellipse_basic.phpt 492 B

123456789101112131415161718192021
  1. --TEST--
  2. Testing imagefilledellipse() of GD library
  3. --SKIPIF--
  4. <?php
  5. if (!extension_loaded("gd")) die("skip GD not present");
  6. ?>
  7. --FILE--
  8. <?php
  9. $image = imagecreatetruecolor(100, 100);
  10. $white = imagecolorallocate($image, 0xFF, 0xFF, 0xFF);
  11. //create an ellipse and fill it with white color
  12. imagefilledellipse($image, 50, 50, 40, 30, $white);
  13. include_once __DIR__ . '/func.inc';
  14. test_image_equals_file(__DIR__ . '/imagefilledellipse_basic.png', $image);
  15. ?>
  16. --EXPECT--
  17. The images are equal.