Jul 15, 2019
3
Level 7
Question regarding codeception test data with laravel
So i landed in a project that has a laravel 5 API with codeception used for testing.
The api.suite config file loads data that it uses to tests via
Db:
dump: tests/_data/dump.sql
As you can see, the dump file is raw sql to create, insert data instead of using factories to use eloquent to populate the test data, making it much easier to work with.
I would like to add this into the process if possible, not touching the way it is currently loading data via the dump file. Is this possible ? Can I add factories to the way codeception loads the data - maybe after the dump is processed, so that going forward we can use that ?
Please or to participate in this conversation.