Skip to content

tests

tests #4

Workflow file for this run

name: tests
on:
push:
branches:
- master
pull_request:
schedule:
- cron: "0 0 * * *"
jobs:
tests:
runs-on: ubuntu-22.04
strategy:
fail-fast: true
matrix:
php: [8.2, 8.3, 8.4]
laravel: [12]
name: PHP ${{ matrix.php }} - Laravel ${{ matrix.laravel }}
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
extensions: dom, curl, libxml, mbstring, zip, ioncube_loader
ini-values: error_reporting=E_ALL
tools: composer:v2
coverage: none
- name: Verify ionCube Loader
run: |
echo "Checking ionCube Loader installation..."
php -m | grep -i ioncube || {
echo "ionCube Loader not found, installing manually..."
# Download ionCube Loaders
wget -O ioncube.tar.gz https://downloads.ioncube.com/loader_downloads/ioncube_loaders_lin_x86-64.tar.gz
tar -xzf ioncube.tar.gz
# Get PHP version info
PHP_VERSION=${{ matrix.php }}
PHP_EXT_DIR=$(php -r "echo ini_get('extension_dir');")
PHP_INI_DIR=$(php --ini | grep "Scan for additional" | cut -d: -f2 | xargs)
# Copy the loader
sudo cp ioncube/ioncube_loader_lin_${PHP_VERSION}.so $PHP_EXT_DIR/
# Create ionCube configuration file with full path
echo "zend_extension=$PHP_EXT_DIR/ioncube_loader_lin_${PHP_VERSION}.so" | sudo tee $PHP_INI_DIR/00-ioncube.ini
echo "ionCube Loader installed successfully"
}
# Final verification
echo "ionCube Loader status:"
php -m | grep -i ioncube
- name: Install dependencies
run: |
composer update --prefer-dist --no-interaction --no-progress --with="illuminate/contracts=^${{ matrix.laravel }}"
- name: Execute tests
run: |
vendor/bin/testbench workbench:build
vendor/bin/testbench package:test
env:
STRIPE_SECRET: ${{ secrets.STRIPE_SECRET }}
CACHE_DRIVER: array