mirror of
https://github.com/php/php-src.git
synced 2026-03-24 00:02:20 +01:00
Disable resource-heavy tests by default (>1GB of memory usage), unless the RUN_RESOURCE_HEAVY_TESTS env variable is set. Fixes GH-20762 Closes GH-20935
36 lines
1.2 KiB
YAML
36 lines
1.2 KiB
YAML
name: Test
|
|
inputs:
|
|
runTestsParameters:
|
|
default: ''
|
|
required: false
|
|
runs:
|
|
using: composite
|
|
steps:
|
|
- shell: bash
|
|
run: |
|
|
set -x
|
|
# XXX: Set up other database tests?
|
|
# XXX: These tests are not running containerized
|
|
export MYSQL_TEST_USER=ci
|
|
export MYSQL_TEST_PASSWD=ci
|
|
if [[ -z "$PDO_MYSQL_TEST_DSN" ]]; then
|
|
export PDO_MYSQL_TEST_DSN="mysql:host=localhost;dbname=test"
|
|
fi
|
|
export PDO_MYSQL_TEST_USER=ci
|
|
export PDO_MYSQL_TEST_PASS=ci
|
|
export PGSQL_TEST_CONNSTR="host=localhost dbname=test port=5432 user=ci password=ci"
|
|
if [[ -z "$PDO_PGSQL_TEST_DSN" ]]; then
|
|
export PDO_PGSQL_TEST_DSN="pgsql:host=localhost port=5432 dbname=test user=ci password=ci"
|
|
fi
|
|
# Slow tests criteron is doubled because this runner isn't as fast as others
|
|
export SKIP_IO_CAPTURE_TESTS=1
|
|
export STACK_LIMIT_DEFAULTS_CHECK=1
|
|
export RUN_RESOURCE_HEAVY_TESTS=1
|
|
sapi/cli/php run-tests.php -P -q ${{ inputs.runTestsParameters }} \
|
|
-j$(nproc) \
|
|
-g FAIL,BORK,LEAK,XLEAK \
|
|
--no-progress \
|
|
--show-diff \
|
|
--show-slow 2000 \
|
|
--set-timeout 120
|