Skip to content

Test current php versions #20

Test current php versions

Test current php versions #20

Workflow file for this run

name: Test
on:
push:
branches:
- main
pull_request:
jobs:
test:
strategy:
matrix:
PHP_VERSION: [ '8.1', '8.3', '8.4' ]
name: Test Apache action
runs-on: ubuntu-latest
steps:
- name: Create fake site
run: |
mkdir /tmp/sut
echo '<?php' | sudo tee /tmp/sut/index.php
echo ' $text = "It works!";' | sudo tee -a /tmp/sut/index.php
echo ' print "<strong>$text</strong>";' | sudo tee -a /tmp/sut/index.php
shell: bash
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.PHP_VERSION }}
- uses: actions/checkout@v2
- name: Setup Apache
uses: ./
with:
php-version: ${{ matrix.PHP_VERSION }}
site-directory: /tmp/sut
http-port: 9090
- name: Test fake site
run: |
curl -sSf http://127.0.0.1:9090