jarektkaczyk / eloquence

Extensions for the Eloquent ORM
http://softonsofa.com
MIT License
1.09k stars 142 forks source link

Cannot write unit tests #248

Closed developernaren closed 5 years ago

developernaren commented 5 years ago

I tried to write a unit test for the model.

but whenever we use fill method on the model, it triggers this query

select column_name as `column_name` from information_schema.columns where table_schema = database and table_name = table

so, it tries and connect to database and is not working in isolation, How can I avoid making this query?

developernaren commented 5 years ago

I tried mocking the model class, and it works.