xref: /PHP-7.4/ext/gd/tests/bug77700.phpt (revision 41fb0eaa)
1--TEST--
2Bug #77700 (Writing truecolor images as GIF ignores interlace flag)
3--SKIPIF--
4<?php
5if (!extension_loaded('gd')) die('skip gd extension not available');
6?>
7--FILE--
8<?php
9$im = imagecreatetruecolor(10, 10);
10imagefilledrectangle($im, 0, 0, 9, 9, imagecolorallocate($im, 255, 255, 255));
11imageinterlace($im, 1);
12imagegif($im, __DIR__ . 'bug77700.gif');
13
14$im = imagecreatefromgif(__DIR__ . 'bug77700.gif');
15var_dump(imageinterlace($im));
16?>
17===DONE===
18--EXPECT--
19int(1)
20===DONE===
21--CLEAN--
22<?php
23unlink(__DIR__ . 'bug77700.gif');
24?>
25