Replies: 1 comment
-
Same for me ! |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I noticed this when I was writing some tests. If I wanted to do something like:
It's contrived, but illustrates an example. Using test driven development,
formatted_title
doesn't exist yet. I haveModel::shouldBeStrict()
set in my app service provider and expected an exception to be thrown, but the test passes. I realised that in this commit there's a note in the commit message that it will Only throw on retrieved models (checked with! $this->wasRecentlyCreated
).I wondered if anyone can tell me why this is the case? Could something untoward happen if this was enabled for models that have only just been created/created with a factory?
Thanks for anyone's thoughts on the matter!
Beta Was this translation helpful? Give feedback.
All reactions