dwightwatson / validating

Automatically validating Eloquent models for Laravel
MIT License
968 stars 76 forks source link

Add Lumen compatibility if facades are disabled #195

Open chrisschaetzlein opened 6 years ago

chrisschaetzlein commented 6 years ago

These changes will allow using this package with Lumen with disabled facades. Tested with the latest 5.5, not sure about older versions.

dwightwatson commented 6 years ago

Unfortunately this breaks all the tests - any idea on how to get the suite back to green when using app()?

chrisschaetzlein commented 6 years ago

Hmm... according to the error reported by Travis: PHP Fatal error: Call to undefined function Watson\Validating\app() I assume that the test runner is not aware of the global app() helper function that Lumen (and afaik Laravel too) provides?