Skip to content

[FrameworkBundle] Use MailerAssertionsTrait in KernelTestCase #35534

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Feb 4, 2020
Merged

[FrameworkBundle] Use MailerAssertionsTrait in KernelTestCase #35534

merged 1 commit into from
Feb 4, 2020

Conversation

adrienfr
Copy link
Contributor

@adrienfr adrienfr commented Jan 31, 2020

Q A
Branch? 4.4+
Bug fix? no
New feature? yes
Deprecations? no
Tickets Fix #35510
License MIT
Doc PR

Since 4.4, we have new PHPUnit constraints for the mailer component, but these are only available with WebTestCase and not KernelTestCase. I think this would be useful to access these constraints from both TestCase.

I don't know if I should move these tests or add new ones only for KernelTestCase?

@fabpot
Copy link
Member

fabpot commented Feb 4, 2020

Thank you @adrienfr.

fabpot added a commit that referenced this pull request Feb 4, 2020
…estCase (adrienfr)

This PR was merged into the 5.1-dev branch.

Discussion
----------

[FrameworkBundle] Use MailerAssertionsTrait in KernelTestCase

| Q             | A
| ------------- | ---
| Branch?       | 4.4+
| Bug fix?      | no
| New feature?  | yes
| Deprecations? | no
| Tickets       | Fix #35510
| License       | MIT
| Doc PR        |

Since 4.4, we have new PHPUnit constraints for the mailer component, but these are only available with `WebTestCase` and not `KernelTestCase`. I think this would be useful to access these constraints from both TestCase.

I don't know if I should move these [tests](https://github.com/symfony/symfony/blob/master/src/Symfony/Bundle/FrameworkBundle/Tests/Functional/MailerTest.php) or add new ones only for `KernelTestCase`?

Commits
-------

1b1ab29 [FrameworkBundle] Use MailerAssertionsTrait in KernelTestCase
@fabpot fabpot merged commit 1b1ab29 into symfony:master Feb 4, 2020
@nicolas-grekas nicolas-grekas modified the milestones: next, 5.1 May 4, 2020
@fabpot fabpot mentioned this pull request May 5, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Mailer] Add a MailerAssertionsTrait in KernelTestCase
4 participants