Skip to content

[Behat] Update main services config from xml to php#18854

Merged
TheMilek merged 1 commit intoSylius:2.3from
NoResponseMate:behat/update-services-definition-to-php
Feb 20, 2026
Merged

[Behat] Update main services config from xml to php#18854
TheMilek merged 1 commit intoSylius:2.3from
NoResponseMate:behat/update-services-definition-to-php

Conversation

@NoResponseMate
Copy link
Copy Markdown
Contributor

@NoResponseMate NoResponseMate commented Feb 20, 2026

Q A
Branch? 2.3
Bug fix? no
New feature? no
BC breaks? no
Deprecations? no
Related tickets partially #18822
License MIT

Summary by CodeRabbit

  • Refactor
    • Consolidated Behat testing framework service configuration, migrating from multiple XML-based definition files to a unified PHP-based configuration format. This streamlines the configuration management for Behat-related testing services, including security contexts, page helpers, and test utilities, resulting in a more maintainable and centralized approach to dependency injection setup.

@NoResponseMate NoResponseMate added the Behat Issues and PRs aimed at improving Behat usage. label Feb 20, 2026
@NoResponseMate NoResponseMate requested review from a team as code owners February 20, 2026 12:41
@NoResponseMate NoResponseMate added the Maintenance CI configurations, READMEs, releases, etc. label Feb 20, 2026
@github-actions
Copy link
Copy Markdown

github-actions bot commented Feb 20, 2026

❌ Preview Environment deleted from Bunnyshell

Available commands:

  • 🚀 /bns:deploy to redeploy the environment

loic425
loic425 previously approved these changes Feb 20, 2026
@coderabbitai
Copy link
Copy Markdown

coderabbitai bot commented Feb 20, 2026

📝 Walkthrough

Walkthrough

This pull request migrates Sylius Behat service definitions from XML to PHP format, introducing a comprehensive PHP configuration file that consolidates all service registrations and replacing the corresponding XML imports and definitions in the container configuration.

Changes

Cohort / File(s) Summary
DI Configuration Migration
src/Sylius/Behat/Resources/config/services.php, src/Sylius/Behat/Resources/config/services.xml
Converts Behat DI service definitions from XML to PHP format. New services.php file registers 300\+ lines of service definitions (security contexts, page helpers, payment components, storage, session management, and testing utilities). XML file reduced to a single import statement, removing prior service definitions and eight XML imports.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Possibly related PRs

Suggested reviewers

  • TheMilek

Poem

🐰 From XML tags to PHP's clean embrace,
Services hop into their rightful place,
Dependencies wired with careful precision,
Behat's helpers dance with newfound vision,
A configuration blessed, refactored with grace! ✨

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and concisely describes the main change: migrating Behat services configuration from XML format to PHP format, which is the primary objective of this pull request.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
  • 📝 Generate docstrings (stacked PR)
  • 📝 Generate docstrings (commit on current branch)
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

Tip

Issue Planner is now in beta. Read the docs and try it out! Share your feedback on Discord.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@src/Sylius/Behat/Resources/config/services.php`:
- Around line 61-72: The array keys in the parameter maps
sylius.behat.notification_checker.admin.class_map and
sylius.behat.notification_checker.shop.class_map are not alphabetized; reorder
each array's keys into alphabetical order (error, failure, info, success)
preserving their associated values so the mapping logic remains unchanged and
coding guidelines are satisfied.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Behat Issues and PRs aimed at improving Behat usage. Maintenance CI configurations, READMEs, releases, etc.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants