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.5] Allow testing anonymous notifiables #21379

Merged
merged 2 commits into from Sep 25, 2017

Conversation

Projects
None yet
3 participants
@themsaid
Member

themsaid commented Sep 25, 2017

Storing the notifiable in the fake notifications array will give us the change to do something like:

Notification::assertSentTo(new AnonymousNotifiable(), Notification::class, function($notification, $channels, $notifiable){
            return $notifiable->routes['mail'] == 'mail@yahoo.com';
        });

themsaid added some commits Sep 25, 2017

@taylorotwell taylorotwell merged commit 2be59db into laravel:5.5 Sep 25, 2017

2 checks passed

continuous-integration/styleci/pr The StyleCI analysis has passed
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
@antonkomarev

This comment has been minimized.

Show comment
Hide comment
@antonkomarev

antonkomarev Sep 25, 2017

Contributor

Thank you @themsaid ! I've tried to write test just yesterday and understand that it's impossible. Was thought to create issue in internals.

Contributor

antonkomarev commented Sep 25, 2017

Thank you @themsaid ! I've tried to write test just yesterday and understand that it's impossible. Was thought to create issue in internals.

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