mirror of
https://github.com/Sylius/Sylius.git
synced 2026-07-14 09:02:12 +00:00
Add builds checking whether the frontend can be built with all supported nodejs versions
Co-authored-by: jaroslavtyc.com <mail@jaroslavtyc.com>
This commit is contained in:
parent
c3da0dc9f8
commit
49e7b7325d
5 changed files with 87 additions and 1 deletions
6
.github/workflows/ci__full.yaml
vendored
6
.github/workflows/ci__full.yaml
vendored
|
|
@ -35,6 +35,12 @@ jobs:
|
|||
name: End-to-end tests (Custom)
|
||||
needs: static-checks
|
||||
uses: ./.github/workflows/ci_e2e-custom.yaml
|
||||
frontend:
|
||||
name: Frontend
|
||||
needs: static-checks
|
||||
uses: ./.github/workflows/ci_frontend.yaml
|
||||
with:
|
||||
type: full
|
||||
packages:
|
||||
name: Packages
|
||||
needs: static-checks
|
||||
|
|
|
|||
6
.github/workflows/ci__minimal.yaml
vendored
6
.github/workflows/ci__minimal.yaml
vendored
|
|
@ -43,6 +43,12 @@ jobs:
|
|||
name: End-to-end tests (Custom)
|
||||
needs: static-checks
|
||||
uses: ./.github/workflows/ci_e2e-custom.yaml
|
||||
frontend:
|
||||
name: Frontend
|
||||
needs: static-checks
|
||||
uses: ./.github/workflows/ci_frontend.yaml
|
||||
with:
|
||||
type: minimal
|
||||
packages:
|
||||
name: Packages
|
||||
needs: static-checks
|
||||
|
|
|
|||
51
.github/workflows/ci_frontend.yaml
vendored
Normal file
51
.github/workflows/ci_frontend.yaml
vendored
Normal file
|
|
@ -0,0 +1,51 @@
|
|||
name: Frontend
|
||||
|
||||
on:
|
||||
workflow_dispatch: ~
|
||||
workflow_call:
|
||||
inputs:
|
||||
type:
|
||||
description: "Type of the build"
|
||||
required: true
|
||||
type: string
|
||||
|
||||
jobs:
|
||||
get-matrix:
|
||||
runs-on: ubuntu-latest
|
||||
name: "Get matrix"
|
||||
outputs:
|
||||
matrix: ${{ steps.matrix.outputs.prop }}
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
- name: "Get matrix"
|
||||
id: matrix
|
||||
uses: notiz-dev/github-action-json-property@release
|
||||
with:
|
||||
path: '.github/workflows/matrix.json'
|
||||
prop_path: '${{ inputs.type }}.frontend'
|
||||
|
||||
frontend:
|
||||
needs: get-matrix
|
||||
runs-on: ubuntu-latest
|
||||
name: "NodeJS ${{ matrix.node }}"
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix: ${{ fromJson(needs.get-matrix.outputs.matrix) }}
|
||||
|
||||
env:
|
||||
APP_ENV: test_cached
|
||||
DATABASE_URL: "mysql://root:root@127.0.0.1/sylius?charset=utf8mb4&serverVersion=8.0"
|
||||
|
||||
steps:
|
||||
-
|
||||
uses: actions/checkout@v3
|
||||
|
||||
- name: Build application
|
||||
uses: SyliusLabs/BuildTestAppAction@v2.0
|
||||
with:
|
||||
build_type: "sylius"
|
||||
e2e_js: "yes"
|
||||
database_version: "8.0"
|
||||
php_version: "8.1"
|
||||
symfony_version: "6.4.*"
|
||||
node_version: ${{ matrix.node }}
|
||||
23
.github/workflows/matrix.json
vendored
23
.github/workflows/matrix.json
vendored
|
|
@ -64,6 +64,13 @@
|
|||
}
|
||||
]
|
||||
},
|
||||
"frontend": {
|
||||
"include": [
|
||||
{
|
||||
"node": "20.x"
|
||||
}
|
||||
]
|
||||
},
|
||||
"packages": {
|
||||
"include": [
|
||||
{
|
||||
|
|
@ -176,6 +183,22 @@
|
|||
}
|
||||
]
|
||||
},
|
||||
"frontend": {
|
||||
"include": [
|
||||
{
|
||||
"node": "14.x"
|
||||
},
|
||||
{
|
||||
"node": "16.x"
|
||||
},
|
||||
{
|
||||
"node": "18.x"
|
||||
},
|
||||
{
|
||||
"node": "20.x"
|
||||
}
|
||||
]
|
||||
},
|
||||
"packages": {
|
||||
"php": [ "8.0", "8.1" ],
|
||||
"symfony": [ "^5.4", "^6.4" ],
|
||||
|
|
|
|||
|
|
@ -47,7 +47,7 @@
|
|||
"yargs": "^17.5.1"
|
||||
},
|
||||
"engines": {
|
||||
"node": "^14 || ^16 || ^18"
|
||||
"node": "^14 || ^16 || ^18 || ^20"
|
||||
},
|
||||
"engineStrict": true,
|
||||
"scripts": {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue