Skip to content

alongal/testing-database-loader

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Testing Database Loader

This is a simple class that loads an entire sql dump file into your required database.

How To Use

    $db = (new \alongal\ImportDb([
            'path_to_mysql_engine' => '/Applications/XAMPP/xamppfiles/bin/mysql',
            'path_to_file_to_load_folder' => realpath(__DIR__ . '/..') . '/tests/',
            'db_name' => 'test_db',
        ]))
            ->setDebugMode(false)
            ->dropDbIfExists(true)
            ->loadFile('test_db_001.sql');

Feel free to contact me: alondagal@gmail.com or @galalon2

About

Import entire database for your own testing purposes.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages