1--TEST-- 2Testing imagecreatetruecolor(): error on out of bound parameters 3--CREDITS-- 4Rafael Dohms <rdohms [at] gmail [dot] com> 5--EXTENSIONS-- 6gd 7--SKIPIF-- 8<?php 9 if (!function_exists("imagecreatetruecolor")) die("skip GD Version not compatible"); 10?> 11--FILE-- 12<?php 13 14require __DIR__ . '/func.inc'; 15 16trycatch_dump( 17 fn() => imagecreatetruecolor(-1, 30), 18 fn() => imagecreatetruecolor(30, -1) 19); 20 21?> 22--EXPECT-- 23!! [ValueError] imagecreatetruecolor(): Argument #1 ($width) must be greater than 0 24!! [ValueError] imagecreatetruecolor(): Argument #2 ($height) must be greater than 0 25