Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
44 changes: 12 additions & 32 deletions .github/workflows/backend-ci.yaml
Original file line number Diff line number Diff line change
@@ -1,61 +1,40 @@
name: CI
name: Backend CI

on:
push:
branches:
- main
- '[0-9]+.[0-9]+'
pull_request: ~
workflow_dispatch: ~

jobs:
cs-fix:
name: Run code style check
runs-on: "ubuntu-24.04"
runs-on: "ubuntu-26.04"
strategy:
matrix:
php:
- '8.3'
steps:
- uses: actions/checkout@v6
- uses: actions/checkout@v7

- uses: ibexa/gh-workflows/actions/composer-install@main
with:
php-version: ${{ matrix.php }}
gh-client-id: ${{ secrets.AUTOMATION_CLIENT_ID }}
gh-client-secret: ${{ secrets.AUTOMATION_CLIENT_SECRET }}
satis-network-key: ${{ secrets.SATIS_NETWORK_KEY }}
satis-network-token: ${{ secrets.SATIS_NETWORK_TOKEN }}

- name: Run code style check
run: composer run-script check-cs -- --format=checkstyle | cs2pr

rector:
name: Run rector
runs-on: "ubuntu-22.04"
strategy:
matrix:
php:
- '8.3'
steps:
- uses: actions/checkout@v6

- name: Setup PHP Action
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
coverage: none
extensions: 'pdo_sqlite, gd'
tools: cs2pr

- uses: ramsey/composer-install@v3
with:
dependency-versions: highest

- name: Run rector
run: vendor/bin/rector process --dry-run --ansi
shell: bash
run: |
set -euo pipefail
composer run-script check-cs -- --format=checkstyle | cs2pr

tests:
name: Unit tests
runs-on: "ubuntu-24.04"
runs-on: "ubuntu-26.04"
timeout-minutes: 15

strategy:
Expand All @@ -66,10 +45,11 @@ jobs:
- '8.4'

steps:
- uses: actions/checkout@v6
- uses: actions/checkout@v7

- uses: ibexa/gh-workflows/actions/composer-install@main
with:
php-version: ${{ matrix.php }}
gh-client-id: ${{ secrets.AUTOMATION_CLIENT_ID }}
gh-client-secret: ${{ secrets.AUTOMATION_CLIENT_SECRET }}
satis-network-key: ${{ secrets.SATIS_NETWORK_KEY }}
Expand Down
25 changes: 14 additions & 11 deletions .github/workflows/integration-tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,21 +3,19 @@ name: Solr integration tests
on:
push:
branches:
- main
- '[0-9]+.[0-9]+'
pull_request: ~

jobs:
solr-integration:
name: "Integration tests"
runs-on: "ubuntu-22.04"
runs-on: "ubuntu-26.04"
strategy:
fail-fast: false
matrix:
php-version:
- '8.3'
solr-version:
- '7.7.3'
- '8.11.2'
- '9.8.1'
cores-setup:
Expand All @@ -37,17 +35,22 @@ jobs:
name: "Set up single core"
run: echo "SOLR_CORES=collection1" >> $GITHUB_ENV

- uses: actions/checkout@v4
- uses: actions/checkout@v7

- name: Setup PHP Action
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php-version }}
coverage: none
- name: Install Composer dependencies
uses: ibexa/gh-workflows/actions/composer-install@main
with:
php-version: ${{ matrix.php-version }}
gh-client-id: ${{ secrets.AUTOMATION_CLIENT_ID }}
gh-client-secret: ${{ secrets.AUTOMATION_CLIENT_SECRET }}
satis-network-key: ${{ secrets.SATIS_NETWORK_KEY }}
satis-network-token: ${{ secrets.SATIS_NETWORK_TOKEN }}

- uses: ramsey/composer-install@v3
- name: Set up Java
uses: actions/setup-java@v6
with:
dependency-versions: highest
distribution: 'temurin'
java-version: '17'

- name: Init Solr
run: ./.github/init_solr.sh
Expand Down
10 changes: 0 additions & 10 deletions .github/workflows/pr-assign.yaml

This file was deleted.

17 changes: 17 additions & 0 deletions .github/workflows/rector.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
name: Rector PHP
on:
push:
branches:
- '[0-9]+.[0-9]+'
pull_request: ~
jobs:
rector:
name: Run rector
uses: ibexa/gh-workflows/.github/workflows/rector.yml@main
with:
php-version: '8.3'
secrets:
AUTOMATION_CLIENT_ID: ${{ secrets.AUTOMATION_CLIENT_ID }}
AUTOMATION_CLIENT_SECRET: ${{ secrets.AUTOMATION_CLIENT_SECRET }}
SATIS_NETWORK_KEY: ${{ secrets.SATIS_NETWORK_KEY }}
SATIS_NETWORK_TOKEN: ${{ secrets.SATIS_NETWORK_TOKEN }}
6 changes: 0 additions & 6 deletions phpstan-baseline.neon
Original file line number Diff line number Diff line change
Expand Up @@ -596,12 +596,6 @@ parameters:
count: 1
path: tests/lib/Search/ResultExtractor/AggregationResultExtractor/RangeAggregationResultExtractorTest.php

-
message: '#^Parameter \#2 \$entries of class Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Search\\AggregationResult\\RangeAggregationResult constructor expects iterable\<Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Search\\AggregationResult\\RangeAggregationResultEntry\<string\|null\>\>, array\{Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Search\\AggregationResult\\RangeAggregationResultEntry\<string\|null\>, Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Search\\AggregationResult\\RangeAggregationResultEntry\<string\>, Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Search\\AggregationResult\\RangeAggregationResultEntry\<string\|null\>\} given\.$#'
identifier: argument.type
count: 1
path: tests/lib/Search/ResultExtractor/AggregationResultExtractor/RangeAggregationResultExtractorTest.php

-
message: '#^Parameter \#1 \$aggregation of method Ibexa\\Solr\\ResultExtractor\\AggregationResultExtractor\\TermAggregationKeyMapper\\ContentTypeAggregationKeyMapper\:\:map\(\) expects Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Query\\Aggregation\\ContentTypeTermAggregation, Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Query\\Aggregation&PHPUnit\\Framework\\MockObject\\MockObject given\.$#'
identifier: argument.type
Expand Down