Annotation of embedaddon/php/ext/gd/tests/xbm2png.phpt, revision 1.1
1.1 ! misho 1: --TEST--
! 2: xbm --> png conversion test
! 3: --SKIPIF--
! 4: <?php
! 5: if (!extension_loaded('gd')) {
! 6: die("skip gd extension not available.");
! 7: }
! 8: if (!function_exists("imagepng")) {
! 9: die("skip png support unavailable");
! 10: }
! 11: if (!function_exists("imagecreatefromxbm")) {
! 12: die("skip xbm read support unavailable");
! 13: }
! 14: ?>
! 15: --FILE--
! 16: <?php
! 17: $cwd = dirname(__FILE__);
! 18:
! 19: echo "XBM to PNG conversion: ";
! 20: echo imagepng(imagecreatefromxbm($cwd . "/conv_test.xbm"), $cwd . "/test_xbm.png") ? 'ok' : 'failed';
! 21: echo "\n";
! 22:
! 23: @unlink($cwd . "/test_xbm.png");
! 24: ?>
! 25: --EXPECT--
! 26: XBM to PNG conversion: ok
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>