diff --git a/Dockerfiles/mods/Dockerfile-5.3 b/Dockerfiles/mods/Dockerfile-5.3
index 87b7a0c..1dcbe02 100644
--- a/Dockerfiles/mods/Dockerfile-5.3
+++ b/Dockerfiles/mods/Dockerfile-5.3
@@ -26,7 +26,6 @@ RUN set -eux \
libjpeg-dev \
libkrb5-dev \
libldap2-dev \
- libmagickwand-dev \
libmcrypt-dev \
libmemcached-dev \
libnghttp2-dev \
@@ -203,17 +202,6 @@ RUN set -eux \
&& true
-# -------------------- Installing PHP Extension: imagick --------------------
-RUN set -eux \
- # Installation: Version specific
- # Type: PECL extension
- # Default: Pecl command
- && pecl install imagick-3.3.0 \
- # Enabling
- && docker-php-ext-enable imagick \
- && true
-
-
# -------------------- Installing PHP Extension: imap --------------------
RUN set -eux \
# Generic pre-command
@@ -689,7 +677,6 @@ RUN set -eux \
libfreetype6 \
libicu52 \
libjpeg62-turbo \
- libmagickwand-6.q16-2 \
libmcrypt4 \
libmemcachedutil2 \
libmysqlclient18 \
@@ -783,8 +770,6 @@ RUN set -eux \
&& php-fpm -m | grep -oiE '^iconv$' \
&& php -m | grep -oiE '^igbinary$' \
&& php-fpm -m | grep -oiE '^igbinary$' \
- && php -m | grep -oiE '^imagick$' \
- && php-fpm -m | grep -oiE '^imagick$' \
&& php -m | grep -oiE '^imap$' \
&& php-fpm -m | grep -oiE '^imap$' \
&& php -m | grep -oiE '^interbase$' \
diff --git a/Dockerfiles/mods/Dockerfile-5.4 b/Dockerfiles/mods/Dockerfile-5.4
index 91acca0..807c5a6 100644
--- a/Dockerfiles/mods/Dockerfile-5.4
+++ b/Dockerfiles/mods/Dockerfile-5.4
@@ -26,7 +26,6 @@ RUN set -eux \
libjpeg-dev \
libkrb5-dev \
libldap2-dev \
- libmagickwand-dev \
libmcrypt-dev \
libmemcached-dev \
libnghttp2-dev \
@@ -203,17 +202,6 @@ RUN set -eux \
&& true
-# -------------------- Installing PHP Extension: imagick --------------------
-RUN set -eux \
- # Installation: Version specific
- # Type: PECL extension
- # Default: Pecl command
- && pecl install imagick \
- # Enabling
- && docker-php-ext-enable imagick \
- && true
-
-
# -------------------- Installing PHP Extension: imap --------------------
RUN set -eux \
# Generic pre-command
@@ -697,7 +685,6 @@ RUN set -eux \
libfreetype6 \
libicu52 \
libjpeg62-turbo \
- libmagickwand-6.q16-2 \
libmcrypt4 \
libmemcachedutil2 \
libmysqlclient18 \
@@ -791,8 +778,6 @@ RUN set -eux \
&& php-fpm -m | grep -oiE '^iconv$' \
&& php -m | grep -oiE '^igbinary$' \
&& php-fpm -m | grep -oiE '^igbinary$' \
- && php -m | grep -oiE '^imagick$' \
- && php-fpm -m | grep -oiE '^imagick$' \
&& php -m | grep -oiE '^imap$' \
&& php-fpm -m | grep -oiE '^imap$' \
&& php -m | grep -oiE '^interbase$' \
diff --git a/Dockerfiles/mods/Dockerfile-5.5 b/Dockerfiles/mods/Dockerfile-5.5
index b81714b..965a009 100644
--- a/Dockerfiles/mods/Dockerfile-5.5
+++ b/Dockerfiles/mods/Dockerfile-5.5
@@ -26,7 +26,6 @@ RUN set -eux \
libjpeg-dev \
libkrb5-dev \
libldap2-dev \
- libmagickwand-dev \
libmcrypt-dev \
libmemcached-dev \
libnghttp2-dev \
@@ -194,17 +193,6 @@ RUN set -eux \
&& true
-# -------------------- Installing PHP Extension: imagick --------------------
-RUN set -eux \
- # Installation: Version specific
- # Type: PECL extension
- # Default: Pecl command
- && pecl install imagick \
- # Enabling
- && docker-php-ext-enable imagick \
- && true
-
-
# -------------------- Installing PHP Extension: imap --------------------
RUN set -eux \
# Generic pre-command
@@ -685,7 +673,6 @@ RUN set -eux \
libfreetype6 \
libicu52 \
libjpeg62-turbo \
- libmagickwand-6.q16-2 \
libmcrypt4 \
libmemcachedutil2 \
libmysqlclient18 \
@@ -779,8 +766,6 @@ RUN set -eux \
&& php-fpm -m | grep -oiE '^iconv$' \
&& php -m | grep -oiE '^igbinary$' \
&& php-fpm -m | grep -oiE '^igbinary$' \
- && php -m | grep -oiE '^imagick$' \
- && php-fpm -m | grep -oiE '^imagick$' \
&& php -m | grep -oiE '^imap$' \
&& php-fpm -m | grep -oiE '^imap$' \
&& php -m | grep -oiE '^interbase$' \
diff --git a/Dockerfiles/mods/Dockerfile-7.4 b/Dockerfiles/mods/Dockerfile-7.4
index 1975990..3985c84 100644
--- a/Dockerfiles/mods/Dockerfile-7.4
+++ b/Dockerfiles/mods/Dockerfile-7.4
@@ -139,7 +139,7 @@ RUN set -eux \
# Installation: Version specific
# Type: Built-in extension
# Custom: configure command
- && docker-php-ext-configure gd --with-gd --with-webp-dir=/usr --with-jpeg-dir=/usr --with-png-dir=/usr --with-zlib-dir=/usr --with-xpm-dir=/usr --with-freetype-dir=/usr --enable-gd-jis-conv \
+ && docker-php-ext-configure gd --enable-gd --with-webp --with-jpeg --with-xpm --with-freetype --enable-gd-jis-conv \
# Installation
&& docker-php-ext-install -j$(getconf _NPROCESSORS_ONLN) gd \
&& true
diff --git a/Dockerfiles/mods/Dockerfile-8.0 b/Dockerfiles/mods/Dockerfile-8.0
index 930f9dc..4cfaf0b 100644
--- a/Dockerfiles/mods/Dockerfile-8.0
+++ b/Dockerfiles/mods/Dockerfile-8.0
@@ -104,7 +104,7 @@ RUN set -eux \
# Installation: Version specific
# Type: Built-in extension
# Custom: configure command
- && docker-php-ext-configure gd --with-gd --with-webp-dir=/usr --with-jpeg-dir=/usr --with-png-dir=/usr --with-zlib-dir=/usr --with-xpm-dir=/usr --with-freetype-dir=/usr --enable-gd-jis-conv \
+ && docker-php-ext-configure gd --enable-gd --with-webp --with-jpeg --with-xpm --with-freetype --enable-gd-jis-conv \
# Installation
&& docker-php-ext-install -j$(getconf _NPROCESSORS_ONLN) gd \
&& true
diff --git a/Dockerfiles/work/Dockerfile-5.2 b/Dockerfiles/work/Dockerfile-5.2
index 2530ee3..0d6819f 100644
--- a/Dockerfiles/work/Dockerfile-5.2
+++ b/Dockerfiles/work/Dockerfile-5.2
@@ -72,6 +72,7 @@ RUN set -eux \
git \
git-flow \
git-svn \
+ ghostscript \
graphviz \
hostname \
htop \
diff --git a/Dockerfiles/work/Dockerfile-5.3 b/Dockerfiles/work/Dockerfile-5.3
index 53c17fb..33671ec 100644
--- a/Dockerfiles/work/Dockerfile-5.3
+++ b/Dockerfiles/work/Dockerfile-5.3
@@ -72,6 +72,7 @@ RUN set -eux \
git \
git-flow \
git-svn \
+ ghostscript \
graphviz \
hostname \
htop \
diff --git a/Dockerfiles/work/Dockerfile-5.4 b/Dockerfiles/work/Dockerfile-5.4
index 7396a7b..6126ba9 100644
--- a/Dockerfiles/work/Dockerfile-5.4
+++ b/Dockerfiles/work/Dockerfile-5.4
@@ -72,6 +72,7 @@ RUN set -eux \
git \
git-flow \
git-svn \
+ ghostscript \
graphviz \
hostname \
htop \
diff --git a/Dockerfiles/work/Dockerfile-5.5 b/Dockerfiles/work/Dockerfile-5.5
index 68567e5..17c7f3b 100644
--- a/Dockerfiles/work/Dockerfile-5.5
+++ b/Dockerfiles/work/Dockerfile-5.5
@@ -72,6 +72,7 @@ RUN set -eux \
git \
git-flow \
git-svn \
+ ghostscript \
graphviz \
hostname \
htop \
diff --git a/Dockerfiles/work/Dockerfile-5.6 b/Dockerfiles/work/Dockerfile-5.6
index e37187f..90484cd 100644
--- a/Dockerfiles/work/Dockerfile-5.6
+++ b/Dockerfiles/work/Dockerfile-5.6
@@ -71,6 +71,7 @@ RUN set -eux \
git \
git-flow \
git-svn \
+ ghostscript \
graphviz \
hostname \
htop \
diff --git a/Dockerfiles/work/Dockerfile-7.0 b/Dockerfiles/work/Dockerfile-7.0
index 7076e11..b1484e4 100644
--- a/Dockerfiles/work/Dockerfile-7.0
+++ b/Dockerfiles/work/Dockerfile-7.0
@@ -71,6 +71,7 @@ RUN set -eux \
git \
git-flow \
git-svn \
+ ghostscript \
graphviz \
hostname \
htop \
diff --git a/Dockerfiles/work/Dockerfile-7.1 b/Dockerfiles/work/Dockerfile-7.1
index d16da52..76ec40f 100644
--- a/Dockerfiles/work/Dockerfile-7.1
+++ b/Dockerfiles/work/Dockerfile-7.1
@@ -71,6 +71,7 @@ RUN set -eux \
git \
git-flow \
git-svn \
+ ghostscript \
graphviz \
hostname \
htop \
diff --git a/Dockerfiles/work/Dockerfile-7.2 b/Dockerfiles/work/Dockerfile-7.2
index f4157a1..772a39c 100644
--- a/Dockerfiles/work/Dockerfile-7.2
+++ b/Dockerfiles/work/Dockerfile-7.2
@@ -71,6 +71,7 @@ RUN set -eux \
git \
git-flow \
git-svn \
+ ghostscript \
graphviz \
hostname \
htop \
diff --git a/Dockerfiles/work/Dockerfile-7.3 b/Dockerfiles/work/Dockerfile-7.3
index 62c3ee2..826f6bb 100644
--- a/Dockerfiles/work/Dockerfile-7.3
+++ b/Dockerfiles/work/Dockerfile-7.3
@@ -71,6 +71,7 @@ RUN set -eux \
git \
git-flow \
git-svn \
+ ghostscript \
graphviz \
hostname \
htop \
diff --git a/Dockerfiles/work/Dockerfile-7.4 b/Dockerfiles/work/Dockerfile-7.4
index ccf10ac..4a214e0 100644
--- a/Dockerfiles/work/Dockerfile-7.4
+++ b/Dockerfiles/work/Dockerfile-7.4
@@ -71,6 +71,7 @@ RUN set -eux \
git \
git-flow \
git-svn \
+ ghostscript \
graphviz \
hostname \
htop \
diff --git a/Dockerfiles/work/Dockerfile-8.0 b/Dockerfiles/work/Dockerfile-8.0
index 6ee29d3..0010e10 100644
--- a/Dockerfiles/work/Dockerfile-8.0
+++ b/Dockerfiles/work/Dockerfile-8.0
@@ -71,6 +71,7 @@ RUN set -eux \
git \
git-flow \
git-svn \
+ ghostscript \
graphviz \
hostname \
htop \
diff --git a/README.md b/README.md
index cb18c67..936a2ed 100644
--- a/README.md
+++ b/README.md
@@ -607,17 +607,17 @@ Check out this table to see which Docker image provides what PHP modules.
| 5.3 |
Core, ctype, curl, date, dom, ereg, fileinfo, filter, hash, iconv, json, libxml, mysql, mysqlnd, openssl, pcre, PDO, pdo_sqlite, Phar, posix, readline, recode, Reflection, session, SimpleXML, SPL, SQLite, sqlite3, standard, tokenizer, xml, xmlreader, xmlwriter, zlib |
- amqp, apc, apcu, bcmath, bz2, calendar, Core, ctype, curl, date, dba, dom, enchant, ereg, exif, fileinfo, filter, ftp, gd, gettext, gmp, hash, iconv, igbinary, imagick, imap, interbase, intl, ioncube, json, ldap, libxml, mbstring, mcrypt, memcache, memcached, mongo, mongodb, msgpack, mysql, mysqli, mysqlnd, OAuth, oci8, openssl, pcntl, pcre, PDO, pdo_dblib, PDO_Firebird, pdo_mysql, pdo_pgsql, pdo_sqlite, pgsql, phalcon, Phar, posix, pspell, rdkafka, readline, recode, redis, Reflection, session, shmop, SimpleXML, snmp, soap, sockets, SPL, SQLite, sqlite3, standard, swoole, sysvmsg, sysvsem, sysvshm, tidy, tokenizer, uploadprogress, wddx, xdebug, xml, xmlreader, xmlrpc, xmlwriter, xsl, Zend OPcache, zip, zlib |
+ amqp, apc, apcu, bcmath, bz2, calendar, Core, ctype, curl, date, dba, dom, enchant, ereg, exif, fileinfo, filter, ftp, gd, gettext, gmp, hash, iconv, igbinary, imap, interbase, intl, ioncube, json, ldap, libxml, mbstring, mcrypt, memcache, memcached, mongo, mongodb, msgpack, mysql, mysqli, mysqlnd, OAuth, oci8, openssl, pcntl, pcre, PDO, pdo_dblib, PDO_Firebird, pdo_mysql, pdo_pgsql, pdo_sqlite, pgsql, phalcon, Phar, posix, pspell, rdkafka, readline, recode, redis, Reflection, session, shmop, SimpleXML, snmp, soap, sockets, SPL, SQLite, sqlite3, standard, swoole, sysvmsg, sysvsem, sysvshm, tidy, tokenizer, uploadprogress, wddx, xdebug, xml, xmlreader, xmlrpc, xmlwriter, xsl, Zend OPcache, zip, zlib |
| 5.4 |
Core, ctype, curl, date, dom, ereg, fileinfo, filter, hash, iconv, json, libxml, mysqlnd, openssl, pcre, PDO, pdo_sqlite, Phar, posix, readline, recode, Reflection, session, SimpleXML, SPL, sqlite3, standard, tokenizer, xml, xmlreader, xmlwriter, zlib |
- amqp, apc, apcu, bcmath, bz2, calendar, Core, ctype, curl, date, dba, dom, enchant, ereg, exif, fileinfo, filter, ftp, gd, gettext, gmp, hash, iconv, igbinary, imagick, imap, interbase, intl, ioncube, json, ldap, libxml, mbstring, mcrypt, memcache, memcached, mongo, mongodb, msgpack, mysql, mysqli, mysqlnd, OAuth, oci8, openssl, pcntl, pcre, PDO, pdo_dblib, PDO_Firebird, pdo_mysql, pdo_pgsql, pdo_sqlite, pgsql, phalcon, Phar, posix, pspell, rdkafka, readline, recode, redis, Reflection, session, shmop, SimpleXML, snmp, soap, sockets, SPL, sqlite3, standard, swoole, sysvmsg, sysvsem, sysvshm, tidy, tokenizer, uploadprogress, wddx, xdebug, xml, xmlreader, xmlrpc, xmlwriter, xsl, Zend OPcache, zip, zlib |
+ amqp, apc, apcu, bcmath, bz2, calendar, Core, ctype, curl, date, dba, dom, enchant, ereg, exif, fileinfo, filter, ftp, gd, gettext, gmp, hash, iconv, igbinary, imap, interbase, intl, ioncube, json, ldap, libxml, mbstring, mcrypt, memcache, memcached, mongo, mongodb, msgpack, mysql, mysqli, mysqlnd, OAuth, oci8, openssl, pcntl, pcre, PDO, pdo_dblib, PDO_Firebird, pdo_mysql, pdo_pgsql, pdo_sqlite, pgsql, phalcon, Phar, posix, pspell, rdkafka, readline, recode, redis, Reflection, session, shmop, SimpleXML, snmp, soap, sockets, SPL, sqlite3, standard, swoole, sysvmsg, sysvsem, sysvshm, tidy, tokenizer, uploadprogress, wddx, xdebug, xml, xmlreader, xmlrpc, xmlwriter, xsl, Zend OPcache, zip, zlib |
| 5.5 |
Core, ctype, curl, date, dom, ereg, fileinfo, filter, ftp, hash, iconv, json, libxml, mbstring, mysqlnd, openssl, pcre, PDO, pdo_sqlite, Phar, posix, readline, Reflection, session, SimpleXML, SPL, sqlite3, standard, tokenizer, xml, xmlreader, xmlwriter, zlib |
- amqp, apc, apcu, bcmath, bz2, calendar, Core, ctype, curl, date, dba, dom, enchant, ereg, exif, fileinfo, filter, ftp, gd, gettext, gmp, hash, iconv, igbinary, imagick, imap, interbase, intl, ioncube, json, ldap, libxml, mbstring, mcrypt, memcache, memcached, mongo, mongodb, msgpack, mysql, mysqli, mysqlnd, OAuth, oci8, openssl, pcntl, pcre, PDO, pdo_dblib, PDO_Firebird, pdo_mysql, pdo_pgsql, pdo_sqlite, pgsql, phalcon, Phar, posix, pspell, rdkafka, readline, recode, redis, Reflection, session, shmop, SimpleXML, snmp, soap, sockets, SPL, sqlite3, standard, swoole, sysvmsg, sysvsem, sysvshm, tidy, tokenizer, uploadprogress, wddx, xdebug, xml, xmlreader, xmlrpc, xmlwriter, xsl, Zend OPcache, zip, zlib |
+ amqp, apc, apcu, bcmath, bz2, calendar, Core, ctype, curl, date, dba, dom, enchant, ereg, exif, fileinfo, filter, ftp, gd, gettext, gmp, hash, iconv, igbinary, imap, interbase, intl, ioncube, json, ldap, libxml, mbstring, mcrypt, memcache, memcached, mongo, mongodb, msgpack, mysql, mysqli, mysqlnd, OAuth, oci8, openssl, pcntl, pcre, PDO, pdo_dblib, PDO_Firebird, pdo_mysql, pdo_pgsql, pdo_sqlite, pgsql, phalcon, Phar, posix, pspell, rdkafka, readline, recode, redis, Reflection, session, shmop, SimpleXML, snmp, soap, sockets, SPL, sqlite3, standard, swoole, sysvmsg, sysvsem, sysvshm, tidy, tokenizer, uploadprogress, wddx, xdebug, xml, xmlreader, xmlrpc, xmlwriter, xsl, Zend OPcache, zip, zlib |
| 5.6 |
diff --git a/build/ansible/DOCKERFILES/Dockerfile-work.j2 b/build/ansible/DOCKERFILES/Dockerfile-work.j2
index 94d99d5..9575f7e 100644
--- a/build/ansible/DOCKERFILES/Dockerfile-work.j2
+++ b/build/ansible/DOCKERFILES/Dockerfile-work.j2
@@ -85,6 +85,7 @@ RUN set -eux \
git \
git-flow \
git-svn \
+ ghostscript \
graphviz \
hostname \
htop \
diff --git a/build/ansible/group_vars/all/mods.yml b/build/ansible/group_vars/all/mods.yml
index 1ae605e..333fe81 100644
--- a/build/ansible/group_vars/all/mods.yml
+++ b/build/ansible/group_vars/all/mods.yml
@@ -295,11 +295,11 @@ extensions_available:
configure: --with-gd --with-webp-dir=/usr --with-jpeg-dir=/usr --with-png-dir=/usr --with-zlib-dir=/usr --with-xpm-dir=/usr --with-freetype-dir=/usr --enable-gd-jis-conv
7.4:
type: builtin
- configure: --with-gd --with-webp-dir=/usr --with-jpeg-dir=/usr --with-png-dir=/usr --with-zlib-dir=/usr --with-xpm-dir=/usr --with-freetype-dir=/usr --enable-gd-jis-conv
+ configure: --enable-gd --with-webp --with-jpeg --with-xpm --with-freetype --enable-gd-jis-conv
run_dep: [libpng16-16, libjpeg62-turbo, libxpm4, libvpx4, libfreetype6, libwebp6]
8.0:
type: builtin
- configure: --with-gd --with-webp-dir=/usr --with-jpeg-dir=/usr --with-png-dir=/usr --with-zlib-dir=/usr --with-xpm-dir=/usr --with-freetype-dir=/usr --enable-gd-jis-conv
+ configure: --enable-gd --with-webp --with-jpeg --with-xpm --with-freetype --enable-gd-jis-conv
run_dep: [libpng16-16, libjpeg62-turbo, libxpm4, libvpx4, libfreetype6, libwebp6]
all:
type: builtin
@@ -340,17 +340,7 @@ extensions_available:
all:
type: pecl
imagick:
- disabled: [5.2, 8.0]
- 5.3:
- type: pecl
- version: 3.3.0
- run_dep: [libmagickwand-6.q16-2]
- 5.4:
- type: pecl
- run_dep: [libmagickwand-6.q16-2]
- 5.5:
- type: pecl
- run_dep: [libmagickwand-6.q16-2]
+ disabled: [5.2, 5.3, 5.4, 5.5, 8.0] # 5.3, 5.4 and 5.5 segfaults
5.6:
type: pecl
run_dep: [libmagickwand-6.q16-3]
diff --git a/tests/mods/01-test-modules.sh b/tests/mods/01-test-modules.sh
new file mode 100755
index 0000000..e52138b
--- /dev/null
+++ b/tests/mods/01-test-modules.sh
@@ -0,0 +1,29 @@
+#!/usr/bin/env bash
+
+set -e
+set -u
+set -o pipefail
+
+CWD="$(cd -P -- "$(dirname -- "$0")" && pwd -P)"
+
+IMAGE="${1}"
+VERSION="${2}"
+FLAVOUR="${3}"
+
+
+# shellcheck disable=SC1090
+. "${CWD}/../.lib.sh"
+
+
+# -------------------------------------------------------------------------------------------------
+# Testing
+# -------------------------------------------------------------------------------------------------
+
+ERROR=0
+for dir in $( ls -1 "${CWD}/modules/" ); do
+ if ! "${CWD}/modules.sh" "${IMAGE}" "${VERSION}" "${FLAVOUR}" "${dir}"; then
+ ERROR="$(( ERROR + 1 ))"
+ fi
+done
+
+exit "${ERROR}"
diff --git a/tests/mods/modules.sh b/tests/mods/modules.sh
new file mode 100755
index 0000000..b293576
--- /dev/null
+++ b/tests/mods/modules.sh
@@ -0,0 +1,80 @@
+#!/usr/bin/env bash
+
+set -e
+set -u
+set -o pipefail
+
+CWD="$(cd -P -- "$(dirname -- "$0")" && pwd -P)"
+
+if [ "${#}" != "4" ]; then
+ >&2 echo "Error, requires 4 arguments: "
+ exit 1
+fi
+
+IMAGE="${1}"
+VERSION="${2}"
+FLAVOUR="${3}"
+MODULE="${4}"
+
+# shellcheck disable=SC1090
+. "${CWD}/../.lib.sh"
+
+
+SKIP_GD=("")
+
+
+echo
+echo "# ------------------------------------------------------------"
+echo "# Testing: ${MODULE}"
+echo "# ------------------------------------------------------------"
+echo
+
+
+# -------------------------------------------------------------------------------------------------
+# Check skipping
+# -------------------------------------------------------------------------------------------------
+
+if [[ ${SKIP_GD[*]} =~ ${VERSION} ]]; then
+ echo "Skipping '${MODULE}' checks for PHP ${VERSION}"
+ exit 0
+fi
+
+
+# -------------------------------------------------------------------------------------------------
+# Testing
+# -------------------------------------------------------------------------------------------------
+
+WORKDIR="/tmp/${MODULE}"
+docker run \
+ --rm \
+ -e DEBUG_ENTRYPOINT=0 \
+ -e NEW_UID="$(id -u)" \
+ -e NEW_GID="$(id -g)" \
+ -v "${CWD}/modules/${MODULE}:${WORKDIR}" \
+ --entrypoint=sh \
+ --workdir="${WORKDIR}" \
+ "${IMAGE}:${VERSION}-${FLAVOUR}" \
+ -c 'find . -name "*.php" -type f -print0 | xargs -0 -n1 sh -c "
+ set -e
+ set -u
+ if [ -f \"\${1:-}\" ]; then
+ fail=0
+ printf \"[TEST] %s\" \"\${1}\"
+
+ if script -e -c \"php \${1}\" /dev/null 2>&1 | grep -Ei \"core|segmentation|fatal|except|err|warn|notice\" 2>&1 >/dev/null; then
+ fail=1
+ fi
+ if ! php \"\${1}\" 2>&1 | grep -E \"^OK$\" 2>&1 >/dev/null; then
+ fail=1
+ fi
+
+ if [ \"\${fail}\" != \"0\" ]; then
+ printf \"\\r[FAIL] %s\\n\" \"\${1}\"
+ php \"\${1}\" || true
+ exit 1
+ else
+ printf \"\\r[OK] %s\\n\" \"\${1}\"
+ fi
+ fi
+
+ " --'
diff --git a/tests/mods/modules/bcmath/bcmath.php b/tests/mods/modules/bcmath/bcmath.php
new file mode 100644
index 0000000..0e318e6
--- /dev/null
+++ b/tests/mods/modules/bcmath/bcmath.php
@@ -0,0 +1,26 @@
+=')) {
+ echo 'OK';
+ exit(0);
+}
+
+/* Set width and height in proportion of genuine PHP logo */
+$width = 400;
+$height = 210;
+
+/* Create an Imagick object with transparent canvas */
+$img = new Imagick();
+
+if ($img->newImage($width, $height, new ImagickPixel('transparent')) !== TRUE) {
+ echo 'FAIL: imagecreatetruecolor()';
+ exit(1);
+}
+
+/* New ImagickDraw instance for ellipse draw */
+$draw = new ImagickDraw();
+/* Set purple fill color for ellipse */
+$draw->setFillColor('#777bb4');
+/* Set ellipse dimensions */
+$draw->ellipse($width / 2, $height / 2, $width / 2, $height / 2, 0, 360);
+/* Draw ellipse onto the canvas */
+$img->drawImage($draw);
+
+/* Reset fill color from purple to black for text (note: we are reusing ImagickDraw object) */
+$draw->setFillColor('black');
+
+if ($img->setImageFormat('png') !== TRUE) {
+ echo 'FAIL: imagecreatetruecolor()';
+ exit(1);
+}
+
+
+echo 'OK';