Skip to content

Commit a375d54

Browse files
committed
Migrate skip checks to --EXTENSIONS-- for ext/gd
Cf. PR #6787. Closes GH-6994.
1 parent a0c44fb commit a375d54

File tree

274 files changed

+549
-812
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

274 files changed

+549
-812
lines changed

ext/gd/tests/001-mb.phpt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
--TEST--
22
imagecreatefrompng() and empty/missing file
3+
--EXTENSIONS--
4+
gd
35
--SKIPIF--
46
<?php if (!function_exists("imagecreatefrompng")) print "skip"; ?>
57
--FILE--

ext/gd/tests/001.phpt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
--TEST--
22
imagecreatefrompng() and empty/missing file
3+
--EXTENSIONS--
4+
gd
35
--SKIPIF--
46
<?php if (!function_exists("imagecreatefrompng")) print "skip"; ?>
57
--FILE--

ext/gd/tests/bug19366.phpt

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
11
--TEST--
22
Bug #19366 (gdimagefill() function crashes (fixed in bundled libgd))
3-
--SKIPIF--
4-
<?php
5-
if (!extension_loaded('gd')) die("skip gd extension not available\n");
6-
?>
3+
--EXTENSIONS--
4+
gd
75
--FILE--
86
<?php
97
echo "Alive: create image\n";

ext/gd/tests/bug22544-mb.phpt

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,7 @@
11
--TEST--
22
Bug #22544 (TrueColor transparency in PNG images).
3-
--SKIPIF--
4-
<?php
5-
if (!extension_loaded('gd')) {
6-
die("skip gd extension not available\n");
7-
}
8-
?>
3+
--EXTENSIONS--
4+
gd
95
--FILE--
106
<?php
117
$image = imageCreateTruecolor(640, 100);

ext/gd/tests/bug22544.phpt

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,7 @@
11
--TEST--
22
Bug #22544 (TrueColor transparency in PNG images).
3-
--SKIPIF--
4-
<?php
5-
if (!extension_loaded('gd')) {
6-
die("skip gd extension not available\n");
7-
}
8-
?>
3+
--EXTENSIONS--
4+
gd
95
--FILE--
106
<?php
117
$image = imageCreateTruecolor(640, 100);

ext/gd/tests/bug24155.phpt

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,9 @@
11
--TEST--
22
Bug #24155 (gdImageRotate270 rotation problem).
3+
--EXTENSIONS--
4+
gd
35
--SKIPIF--
46
<?php
5-
if (!extension_loaded('gd')) {
6-
die("skip gd extension not available\n");
7-
}
87
if (!function_exists("imagerotate")) die("skip requires bundled GD library\n");
98
?>
109
--FILE--

ext/gd/tests/bug24594.phpt

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,7 @@
11
--TEST--
22
Bug #24594 (Filling an area using tiles).
3-
--SKIPIF--
4-
<?php
5-
if (!extension_loaded('gd')) {
6-
die("skip gd extension not available\n");
7-
}
8-
?>
3+
--EXTENSIONS--
4+
gd
95
--FILE--
106
<?php
117
$tile = imagecreate(36,36);

ext/gd/tests/bug27582_1.phpt

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
11
--TEST--
22
Bug #27582 (ImageFillToBorder() on alphablending image looses alpha on fill color)
3-
--SKIPIF--
4-
<?php
5-
if (!extension_loaded('gd')) die("skip gd extension not available\n");
6-
?>
3+
--EXTENSIONS--
4+
gd
75
--FILE--
86
<?php
97
$dest = dirname(realpath(__FILE__)) . '/bug27582.png';

ext/gd/tests/bug28147.phpt

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
11
--TEST--
22
Bug #28147 (Crash with anti-aliased line)
3-
--SKIPIF--
4-
<?php
5-
if (!extension_loaded('gd')) die("skip gd extension not available\n");
6-
?>
3+
--EXTENSIONS--
4+
gd
75
--FILE--
86
<?php
97
//

ext/gd/tests/bug36697-mb.phpt

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,7 @@
11
--TEST--
22
Bug #36697 (TrueColor transparency with GIF palette output).
3-
--SKIPIF--
4-
<?php
5-
if (!extension_loaded('gd')) {
6-
die("skip gd extension not available\n");
7-
}
8-
?>
3+
--EXTENSIONS--
4+
gd
95
--FILE--
106
<?php
117
$dest = __DIR__ . "/36697私はガラスを食べられます.gif";

ext/gd/tests/bug36697.phpt

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,7 @@
11
--TEST--
22
Bug #36697 (TrueColor transparency with GIF palette output).
3-
--SKIPIF--
4-
<?php
5-
if (!extension_loaded('gd')) {
6-
die("skip gd extension not available\n");
7-
}
8-
?>
3+
--EXTENSIONS--
4+
gd
95
--FILE--
106
<?php
117
$dest = __DIR__ . "/36697.gif";

ext/gd/tests/bug37346-mb.phpt

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
11
--TEST--
22
Bug #37346 (gdimagecreatefromgif, bad colormap)
3-
--SKIPIF--
4-
<?php
5-
if (!extension_loaded('gd')) die("skip gd extension not available\n");
6-
?>
3+
--EXTENSIONS--
4+
gd
75
--FILE--
86
<?php
97
$im = imagecreatefromgif(__DIR__ . '/bug37346私はガラスを食べられます.gif');

ext/gd/tests/bug37346.phpt

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
11
--TEST--
22
Bug #37346 (gdimagecreatefromgif, bad colormap)
3-
--SKIPIF--
4-
<?php
5-
if (!extension_loaded('gd')) die("skip gd extension not available\n");
6-
?>
3+
--EXTENSIONS--
4+
gd
75
--FILE--
86
<?php
97
$im = imagecreatefromgif(__DIR__ . '/bug37346.gif');

ext/gd/tests/bug37360.phpt

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
11
--TEST--
22
Bug #37360 (gdimagecreatefromgif, bad image sizes)
3-
--SKIPIF--
4-
<?php
5-
if (!extension_loaded('gd')) die("skip gd extension not available\n");
6-
?>
3+
--EXTENSIONS--
4+
gd
75
--FILE--
86
<?php
97
$im = imagecreatefromgif(__DIR__ . '/bug37360.gif');

ext/gd/tests/bug38112.phpt

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,7 @@
11
--TEST--
22
Bug #38112 (GIF Invalid Code size ).
3-
--SKIPIF--
4-
<?php
5-
if (!extension_loaded('gd')) {
6-
die("skip gd extension not available\n");
7-
}
8-
?>
3+
--EXTENSIONS--
4+
gd
95
--FILE--
106
<?php
117
$im = imagecreatefromgif(__DIR__ . '/bug38112.gif');

ext/gd/tests/bug38179.phpt

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
11
--TEST--
22
Bug #38179 (imagecopy from a palette to a truecolor image loses alpha channel)
3-
--SKIPIF--
4-
<?php
5-
if (!function_exists('imagecopy')) die("skip gd extension not available\n");
6-
?>
3+
--EXTENSIONS--
4+
gd
75
--FILE--
86
<?php
97
$src = imagecreate(5,5);

ext/gd/tests/bug38212-mb.phpt

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
11
--TEST--
22
Bug #38212 (Seg Fault on invalid imagecreatefromgd2part() parameters)
3-
--SKIPIF--
4-
<?php
5-
if (!function_exists('imagecopy')) die("skip gd extension not available\n");
6-
?>
3+
--EXTENSIONS--
4+
gd
75
--FILE--
86
<?php
97
require __DIR__ . '/func.inc';

ext/gd/tests/bug38212.phpt

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
11
--TEST--
22
Bug #38212 (Seg Fault on invalid imagecreatefromgd2part() parameters)
3-
--SKIPIF--
4-
<?php
5-
if (!function_exists('imagecopy')) die("skip gd extension not available\n");
6-
?>
3+
--EXTENSIONS--
4+
gd
75
--FILE--
86
<?php
97
require __DIR__ . '/func.inc';

ext/gd/tests/bug39082.phpt

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,7 @@
11
--TEST--
22
Bug #39082 (Output image to stdout segfaults).
3-
--SKIPIF--
4-
<?php
5-
if (!extension_loaded('gd')) {
6-
die("skip gd extension not available\n");
7-
}
8-
?>
3+
--EXTENSIONS--
4+
gd
95
--FILE--
106
<?php
117
$im = imagecreatetruecolor(1,1);

ext/gd/tests/bug39273.phpt

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
11
--TEST--
22
Bug #37360 (gdimagecreatefromgif, bad image sizes)
3-
--SKIPIF--
4-
<?php
5-
if (!extension_loaded('gd')) die("skip gd extension not available\n");
6-
?>
3+
--EXTENSIONS--
4+
gd
75
--FILE--
86
<?php
97
$small = imagecreatetruecolor(10, 10);

ext/gd/tests/bug39366.phpt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
--TEST--
22
Bug #39366 (imagerotate does not respect alpha with angles>45)
3+
--EXTENSIONS--
4+
gd
35
--SKIPIF--
46
<?php
5-
if (!extension_loaded('gd')) die("skip gd extension not available\n");
67
if (!function_exists("imagerotate")) die("skip requires bundled GD library\n");
78
?>
89
--FILE--

ext/gd/tests/bug39508.phpt

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
11
--TEST--
22
Bug #39508 (imagefill crashes with small images 3 pixels or less)
3-
--SKIPIF--
4-
<?php
5-
if (!extension_loaded('gd')) die("skip gd extension not available\n");
6-
?>
3+
--EXTENSIONS--
4+
gd
75
--FILE--
86
<?php
97
$im = imagecreatetruecolor(3,1);

ext/gd/tests/bug39780.phpt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
--TEST--
22
Bug #39780 (PNG image with CRC/data error raises a fatal error)
3+
--EXTENSIONS--
4+
gd
35
--SKIPIF--
46
<?php
5-
if (!extension_loaded('gd')) die("skip gd extension not available\n");
67
if (!GD_BUNDLED) die("skip requires bundled GD library\n");
78
?>
89
--FILE--

ext/gd/tests/bug39780_extern.phpt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
--TEST--
22
Bug #39780 (PNG image with CRC/data error raises a fatal error)
3+
--EXTENSIONS--
4+
gd
35
--SKIPIF--
46
<?php
5-
if (!extension_loaded('gd')) die("skip gd extension not available\n");
67
if (GD_BUNDLED) die("skip requires extern GD\n");
78
?>
89
--FILE--

ext/gd/tests/bug40764.phpt

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
11
--TEST--
22
Bug #40764 (line thickness not respected for horizontal and vertical lines)
3-
--SKIPIF--
4-
<?php
5-
if (!extension_loaded('gd')) die("skip gd extension not available\n");
6-
?>
3+
--EXTENSIONS--
4+
gd
75
--FILE--
86
<?php
97
$image=imagecreatetruecolor(400, 400);

ext/gd/tests/bug41442.phpt

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,9 @@
11
--TEST--
22
Bug #41442 (imagegd2() under output control)
3+
--EXTENSIONS--
4+
gd
35
--SKIPIF--
46
<?php
5-
if (!extension_loaded('gd')) {
6-
die("skip gd extension not available.");
7-
}
87
if (!function_exists("imagegd2")) {
98
die("skip GD2 support unavailable");
109
}

ext/gd/tests/bug42434.phpt

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,7 @@
11
--TEST--
22
Bug #42434 (ImageLine w/ antialias = 1px shorter)
3-
--SKIPIF--
4-
<?php
5-
if (!extension_loaded('gd')) {
6-
die('skip gd extension not available');
7-
}
8-
?>
3+
--EXTENSIONS--
4+
gd
95
--FILE--
106
<?php
117
$im = imagecreatetruecolor(10, 2);

ext/gd/tests/bug43073.phpt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
--TEST--
22
Bug #43073 (TrueType bounding box is wrong for angle<>0)
3+
--EXTENSIONS--
4+
gd
35
--SKIPIF--
46
<?php
5-
if(!extension_loaded('gd')){ die('skip gd extension not available'); }
67
if(!function_exists('imagettftext')) die('skip imagettftext() not available');
78
?>
89
--FILE--

ext/gd/tests/bug43121.phpt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
--TEST--
22
Bug #43121 (gdImageFill with IMG_COLOR_TILED crashes httpd)
3+
--EXTENSIONS--
4+
gd
35
--SKIPIF--
46
<?php
5-
if (!extension_loaded('gd')) die("skip gd extension not available\n");
67
if (!GD_BUNDLED && version_compare(GD_VERSION, '2.2.0', '<')) {
78
die("skip test requires GD 2.2.0 or higher");
89
}

ext/gd/tests/bug43475.phpt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
--TEST--
22
Bug #43475 (Thick styled lines have scrambled patterns)
3+
--EXTENSIONS--
4+
gd
35
--SKIPIF--
46
<?php
5-
if (!extension_loaded('gd')) die("skip gd extension not available\n");
67
if (!GD_BUNDLED && version_compare(GD_VERSION, '2.2.2', '<')) {
78
die("skip test requires GD 2.2.2 or higher");
89
}

ext/gd/tests/bug43828.phpt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
--TEST--
22
Bug #43828 (broken transparency of imagearc for truecolor in blendingmode)
3+
--EXTENSIONS--
4+
gd
35
--SKIPIF--
46
<?php
5-
if (!extension_loaded('gd')) die('skip ext/gd not available');
67
if (!GD_BUNDLED && version_compare(GD_VERSION, '2.2.2', '<')) {
78
die("skip test requires GD 2.2.2 or higher");
89
}

ext/gd/tests/bug44849.phpt

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
11
--TEST--
22
Bug #44849 (imagecolorclosesthwb is not available on Windows)
3-
--SKIPIF--
4-
<?php
5-
if(!extension_loaded('gd')){ die('skip gd extension not available'); }
6-
?>
3+
--EXTENSIONS--
4+
gd
75
--FILE--
86
<?php
97
var_dump(function_exists('imagecolorclosesthwb'));

ext/gd/tests/bug45799.phpt

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
11
--TEST--
22
Bug #45799 (imagepng() crashes on empty image).
3-
--SKIPIF--
4-
<?php
5-
if (!extension_loaded('gd')) die("skip gd extension not available\n");
6-
?>
3+
--EXTENSIONS--
4+
gd
75
--FILE--
86
<?php
97
$img = imagecreate(500,500);

0 commit comments

Comments
 (0)