Development environment for Kisakone.
- Have Virtualbox and Vagrant installed and working.
vagrant up
. Lots of output will happen.- Browse to install.php with browser for completing installation.
- Use hostname
localhost
, databasekisakone
, userroot
, passwordpass
and table prefixkisakone_
for default installation options.
Now you can modify files at your OS and changes are synced automatically to VM. Kisakone is live at localhost
When done with development, delete the box: vagrant destroy -f
.
Code is safe as it is residing outside the box (../kisakone/
).
After you have once completed the installation, take a backup from your database:
- Enter Vagrant VM:
vagrant ssh
- Execute
mysqldump -uroot -ppass kisakone > /vagrant/kisakone.sql.backup
From now on, when you do vagrant destroy -f && vagrant up
to start from a clean slate,
database will be restored from this backup and you don't need to manually do the installation anymore.
There is two types of testing available. Coverage is tiny still, but fixing legacy PHP code testing five years after the code has been written into spaghetti, is... not easy.
- Unit tests: Outside Vagrant, run
./run_unittests.sh
. It executes unittests within running instance. - Functional tests: run
./run_tests.sh
. It executes series of Selenium tests and interacts with the web app UI.