1--TEST--
2Testing imagerectangle() of GD library
3--CREDITS--
4Ivan Rosolen <contato [at] ivanrosolen [dot] com>
5#testfest PHPSP on 2009-06-30
6--EXTENSIONS--
7gd
8--SKIPIF--
9<?php
10if (!(imagetypes() & IMG_PNG)) {
11    die("skip No PNG support");
12}
13?>
14--FILE--
15<?php
16// Create a image
17$image = imagecreatetruecolor( 100, 100 );
18
19// Draw a rectangle
20imagerectangle( $image, 0, 0, 50, 50, imagecolorallocate($image, 255, 255, 255) );
21
22include_once __DIR__ . '/func.inc';
23test_image_equals_file(__DIR__ . '/imagerectangle_basic.png', $image);
24?>
25--EXPECT--
26The images are equal.
27