summaryrefslogtreecommitdiff
path: root/ext/gd/tests/imagecolormatch_basic.phpt
diff options
context:
space:
mode:
Diffstat (limited to 'ext/gd/tests/imagecolormatch_basic.phpt')
-rw-r--r--ext/gd/tests/imagecolormatch_basic.phpt19
1 files changed, 19 insertions, 0 deletions
diff --git a/ext/gd/tests/imagecolormatch_basic.phpt b/ext/gd/tests/imagecolormatch_basic.phpt
new file mode 100644
index 0000000..1d18812
--- /dev/null
+++ b/ext/gd/tests/imagecolormatch_basic.phpt
@@ -0,0 +1,19 @@
+--TEST--
+Basic test imagecolormatch() of GD library
+--CREDITS--
+Paulo Alves de Sousa Filho <pspalves [at] gmail [dot] com>
+#testfest PHPSP on 2009-06-20
+--SKIPIF--
+<?php
+if (!extension_loaded("gd")) die("skip GD not present");
+?>
+--FILE--
+<?php
+$ima = imagecreatetruecolor(110, 20);
+$background_color = imagecolorallocate($ima, 0, 0, 0);
+$imb = imagecreate(110, 20);
+$background_color = imagecolorallocate($imb, 0, 0, 100);
+var_dump(imagecolormatch($ima, $imb));
+?>
+--EXPECTF--
+bool(true)