@@ -13,14 +13,19 @@ jobs:
13
13
runs-on : ubuntu-latest
14
14
15
15
steps :
16
- - name : Set PHP Version
17
- run : sudo update-alternatives --set php /usr/bin/php7.4
16
+ - name : ' Checkout code '
17
+ uses : actions/checkout@v3
18
18
19
- - name : Checkout
20
- uses : actions/checkout@v2
19
+ - name : ' Install PHP'
20
+ uses : shivammathur/setup-php@v2
21
+ with :
22
+ coverage : none
23
+ php-version : 7.4
24
+ tools : composer:v2
25
+ ini-values : date.timezone=UTC
21
26
22
- - name : Validate
23
- run : composer validate --strict
27
+ - name : Validate composer.json file
28
+ run : composer validate --strict
24
29
25
30
stable-tests :
26
31
name : Stable Tests
@@ -29,27 +34,19 @@ jobs:
29
34
strategy :
30
35
fail-fast : false
31
36
matrix :
32
- php-versions : [ '7.4', '8.0' ]
37
+ php-version : ['7.4', '8.0']
33
38
34
39
steps :
35
- - name : Set PHP Version
36
- run : sudo update-alternatives --set php /usr/bin/php${{ matrix.php-versions }}
37
-
38
- - name : Get PHP Version
39
- run : |
40
- ver=$(php -v | grep -oP '(?<=PHP )\d.\d')
41
- echo "::set-output name=version::$ver"
42
- id : php-ver
43
-
44
- - name : Using PHP Version from matrix
45
- run : |
46
- echo "Runner is not using PHP Version defined in the php-versions matrix."
47
- php -v
48
- exit 1
49
- if : steps.php-ver.outputs.version != matrix.php-versions
50
-
51
- - name : Checkout
52
- uses : actions/checkout@v2
40
+ - name : ' Checkout code'
41
+ uses : actions/checkout@v3
42
+
43
+ - name : ' Install PHP'
44
+ uses : shivammathur/setup-php@v2
45
+ with :
46
+ coverage : none
47
+ php-version : ${{ matrix.php-version }}
48
+ tools : composer:v2
49
+ ini-values : date.timezone=UTC
53
50
54
51
- name : Install Composer Dependencies
55
52
run : composer install --no-progress
0 commit comments