Skip to content

Commit a9975d8

Browse files
Resolve conflicts between 2.2 and 3.0
2 parents 251d581 + 3a63bd3 commit a9975d8

File tree

706 files changed

+6382
-9563
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

706 files changed

+6382
-9563
lines changed

.github/workflows/build.yml

Lines changed: 61 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -13,21 +13,35 @@ jobs:
1313
tests:
1414
runs-on: ubuntu-latest
1515

16-
name: "Sylius ${{ matrix.sylius }}, PHP ${{ matrix.php }}, Symfony ${{ matrix.symfony }}, MySQL ${{ matrix.mysql }}, AOC ${{ matrix.admin_order_creation }}"
16+
name: "Sylius ${{ matrix.sylius }}, PHP ${{ matrix.php }}, Symfony ${{ matrix.symfony }}, State Machine ${{ matrix.state_machine_adapter }}, Refund ${{ matrix.refund }}"
1717

1818
strategy:
1919
fail-fast: false
2020
matrix:
21-
php: [ "8.1" ]
22-
node: [ "20.x" ]
23-
mysql: [ "8.4" ]
24-
symfony: [ "^6.4" ]
25-
sylius: [ "~1.13.11", "~1.14.4" ]
26-
admin_order_creation: [ "no", "yes" ]
21+
php: ["8.3"]
22+
symfony: ["^6.4", "~7.3.0"]
23+
sylius: ["~2.0.8", "~2.1.0"]
24+
node: ["22.x"]
25+
database: ["mysql"]
26+
mysql: ["8.4"]
27+
state_machine_adapter: ["symfony_workflow"]
28+
refund: ["false", "true"]
29+
30+
include:
31+
-
32+
php: "8.3"
33+
symfony: "~7.3.0"
34+
sylius: "~2.1.0"
35+
node: "24.x"
36+
database: "mysql"
37+
mysql: "8.4"
38+
state_machine_adapter: "winzou_state_machine"
39+
refund: "false"
2740

2841
env:
2942
APP_ENV: test
3043
DATABASE_URL: "mysql://root:root@127.0.0.1/sylius?serverVersion=${{ matrix.mysql }}"
44+
TEST_SYLIUS_STATE_MACHINE_ADAPTER: "${{ matrix.state_machine_adapter }}"
3145

3246
steps:
3347
- uses: actions/checkout@v4
@@ -60,12 +74,6 @@ jobs:
6074
- name: Install certificates
6175
run: symfony server:ca:install
6276

63-
- name: Run Chrome Headless
64-
run: google-chrome-stable --enable-automation --disable-background-networking --no-default-browser-check --no-first-run --disable-popup-blocking --disable-default-apps --allow-insecure-localhost --disable-translate --disable-extensions --no-sandbox --enable-features=Metal --headless --remote-debugging-port=9222 --window-size=2880,1800 --proxy-server='direct://' --proxy-bypass-list='*' http://127.0.0.1 > /dev/null 2>&1 &
65-
66-
- name: Run webserver
67-
run: (cd tests/Application && symfony server:start --port=8080 --dir=public --daemon)
68-
6977
- name: Get Composer cache directory
7078
id: composer-cache
7179
run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT
@@ -78,10 +86,6 @@ jobs:
7886
restore-keys: |
7987
${{ runner.os }}-php-${{ matrix.php }}-composer-
8088
81-
- name: Install Sylius version
82-
run: |
83-
composer require "sylius/sylius:${{ matrix.sylius }}" --no-update
84-
8589
- name: Restrict Symfony version
8690
if: matrix.symfony != ''
8791
run: |
@@ -93,13 +97,16 @@ jobs:
9397
if: matrix.sylius != ''
9498
run: composer require "sylius/sylius:${{ matrix.sylius }}" --no-update --no-scripts --no-interaction
9599

96-
- name: Install AdminOrderCreation plugin
97-
if: matrix.admin_order_creation == 'yes'
98-
run: composer require "sylius/admin-order-creation-plugin:~0.14.0 || ~0.15.0 || ~0.16.0" --no-update --no-scripts --no-interaction
100+
- name: Install Refund Plugin
101+
if: matrix.refund == 'true'
102+
run: composer require "sylius/refund-plugin" --no-update --no-scripts --no-interaction
99103

100104
- name: Install PHP dependencies
101105
run: composer install --no-interaction
102106

107+
- name: Validate composer.json
108+
run: composer validate --ansi --strict
109+
103110
- name: Run PHPStan
104111
run: vendor/bin/phpstan analyse
105112

@@ -110,7 +117,7 @@ jobs:
110117
run: vendor/bin/phpunit --colors=always --testsuite=unit
111118

112119
- name: Validate container
113-
run: (cd tests/Application && bin/console lint:container)
120+
run: vendor/bin/console lint:container
114121

115122
- name: Get Yarn cache directory
116123
id: yarn-cache
@@ -124,37 +131,54 @@ jobs:
124131
restore-keys: |
125132
${{ runner.os }}-node-${{ matrix.node }}-yarn-
126133
127-
- name: Install JS dependencies
128-
run: (cd tests/Application && yarn install)
134+
-
135+
name: Install JS dependencies
136+
run: (cd vendor/sylius/test-application && yarn install)
129137

130-
- name: Prepare test application database
138+
-
139+
name: Prepare test application database
131140
run: |
132-
(cd tests/Application && bin/console doctrine:database:create -vvv)
133-
(cd tests/Application && bin/console doctrine:migrations:migrate -n -vvv -q)
141+
vendor/bin/console doctrine:database:create -vvv
142+
vendor/bin/console doctrine:migrations:migrate -n -vvv -q
134143
135-
- name: Validate database schema
136-
run: (cd tests/Application && bin/console doctrine:schema:validate -vvv)
144+
-
145+
name: Validate database schema
146+
run: vendor/bin/console doctrine:schema:validate
137147

138-
- name: Prepare test application assets
148+
-
149+
name: Prepare test application assets
139150
run: |
140-
(cd tests/Application && bin/console assets:install public -vvv)
141-
(cd tests/Application && yarn build)
151+
vendor/bin/console assets:install -vvv
152+
(cd vendor/sylius/test-application && yarn build)
142153
143-
- name: Prepare test application cache
144-
run: (cd tests/Application && bin/console cache:warmup -vvv)
154+
-
155+
name: Prepare test application cache
156+
run: vendor/bin/console cache:warmup -vvv
145157

146-
- name: Load fixtures in test application
147-
run: (cd tests/Application && bin/console sylius:fixtures:load -n)
158+
-
159+
name: Load fixtures in test application
160+
run: vendor/bin/console sylius:fixtures:load -n
161+
162+
-
163+
name: Validate container
164+
run: vendor/bin/console lint:container
148165

149166
- name: Run Mockoon CLI
150167
uses: mockoon/cli-action@v2
151168
with:
152169
version: "latest"
153-
data-file: tests/Functional/Mockoon.json
170+
data-file: tests/Integration/Refund/Functional/Mockoon.json
154171
port: 8217
155172

156173
- name: Run Functional Tests
157-
run: vendor/bin/phpunit --colors=always --testsuite=functional
174+
if: matrix.refund == 'true'
175+
run: vendor/bin/phpunit --colors=always --testsuite=integration-refund
176+
177+
- name: Run Chrome Headless
178+
run: google-chrome-stable --enable-automation --disable-background-networking --no-default-browser-check --no-first-run --disable-popup-blocking --disable-default-apps --allow-insecure-localhost --disable-translate --disable-extensions --no-sandbox --enable-features=Metal --headless --remote-debugging-port=9222 --window-size=2880,1800 --proxy-server='direct://' --proxy-bypass-list='*' http://127.0.0.1 > /dev/null 2>&1 &
179+
180+
- name: Run webserver
181+
run: symfony server:start --port=8080 --daemon
158182

159183
- name: Run Mockoon for Behat
160184
shell: bash
@@ -165,10 +189,6 @@ jobs:
165189
run: |
166190
vendor/bin/behat --colors --strict -f progress -vvv --no-interaction || vendor/bin/behat --colors --strict -vvv --no-interaction --rerun
167191
168-
- name: Run AdminOrderCreation Behat
169-
if: matrix.admin_order_creation == 'yes'
170-
run: vendor/bin/behat --colors --strict -f progress -vvv --no-interaction --profile=admin_order_creation || vendor/bin/behat --colors --strict -vvv --no-interaction --profile=admin_order_creation --rerun
171-
172192
- name: Upload Behat logs
173193
uses: actions/upload-artifact@v4
174194
if: failure()

.github/workflows/upmerge_pr.yaml

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -20,18 +20,15 @@ jobs:
2020
fail-fast: false
2121
matrix:
2222
include:
23-
-
24-
base_branch: "1.0"
25-
target_branch: "2.0"
26-
-
27-
base_branch: "2.0"
28-
target_branch: "2.1"
2923
-
3024
base_branch: "2.1"
3125
target_branch: "2.2"
3226
-
3327
base_branch: "2.2"
3428
target_branch: "3.0"
29+
-
30+
base_branch: "3.0"
31+
target_branch: "3.1"
3532

3633
steps:
3734
-

.gitignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,3 +21,7 @@ composer.lock
2121
/behat.yml
2222
/phpunit.xml
2323
/phpstan.neon
24+
25+
/tests/TestApplication/.env.local
26+
/tests/TestApplication/.env.*.local
27+
/var/

0 commit comments

Comments
 (0)