-
Notifications
You must be signed in to change notification settings - Fork 11.1k
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
[5.8] Bugfix - QueueFake size method and added a test #29761
Conversation
This will break if the queue is null? |
@GrahamCampbell thats why I put first assertion in the test without pushing anything to a queue:
there is initializer for
|
No, I mean if there are jobs, but the queue name is null, it should be non-zero. |
To clarify, in Laravel, using null for the queue name means "use the default". This needs to be handled within the implementation. |
@GrahamCampbell , here are my explanations in the test, please consider if possible to explain what's wrong based on the test:
If you're talking about |
I think you can already assert on Queue::pushedJobs() when using the fake. I'm not sure having |
@taylorotwell you interpret this wrong, I'm testing my code which expose Queue::size through API. Since I'm faking queue and testing API which calling size() - as a developer I expect |
@hlorofos we got this merged 👍 |
@driesvints appreciate all your help along the way! |
This is fixing #29755