Page 1 of 1

how do i deal with a migration file for testing ?

Posted: Tue Oct 06, 2015 6:36 am
by gautamz07
Just had a question about migration , was reading the link here:

http://laravel.com/docs/5.1/migrations,

now suppose i create a table just for testing something random in my application , say i do something like:

Code: Select all

php artisan migrate:make create_testing_fileupload
now once i am done testing obviously i don't want this file to be in my project do i drop the table from the database, but the file is still there, so do i just delete the file ? because obviously when i push the project to git or some version control system, i don't want the guy haveing a migration file that was just meant for testing and then for him/her to have an additional unwanted table in their database.

so basically how do i deal with a migration file that was just meant for testing ?

Thank you.
Gautam.

Re: how do i deal with a migration file for testing ?

Posted: Tue Oct 06, 2015 6:47 am
by Celauran
If it was a temporary table just for use in development, I'd either create it by hand rather than writing a migration for it at all, or just delete the migration before deploying.

Re: how do i deal with a migration file for testing ?

Posted: Tue Oct 06, 2015 7:33 am
by gautamz07
Well , thats all i wanted to know :D ... thanks