File: integration.yml

package info (click to toggle)
php-http-psr7-integration-tests 1.4.0-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 452 kB
  • sloc: php: 1,593; makefile: 19
file content (39 lines) | stat: -rw-r--r-- 1,218 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
on:
  workflow_call:
    inputs:
      php:
        required: true
        type: string
      suite:
        required: true
        type: string
      package:
        required: true
        type: string

jobs:
  latest:
    name: ${{ inputs.suite }} PHP ${{ inputs.php }}
    runs-on: ubuntu-latest

    steps:
      - name: Checkout code
        uses: actions/checkout@v4

      - name: Setup PHP
        uses: shivammathur/setup-php@v2
        with:
          php-version: ${{ inputs.php }}
          tools: composer
          coverage: none

      - name: Install dependencies
        # we need to remove all dev dependencies to avoid failures due to php version constraints
        # then we install the dependencies
        # and finally require the implementation to test with source flag (to get integration test cases that might be excluded in git-attributes)
        run: |
          composer remove --dev guzzlehttp/psr7 laminas/laminas-diactoros nyholm/psr7 ringcentral/psr7 slim/psr7 httpsoft/http-message --no-update
          composer require ${{ inputs.package }} --no-interaction --no-progress --prefer-source

      - name: Execute tests
        run: composer test -- --testsuite ${{ inputs.suite }}