Skip to content

Instantly share code, notes, and snippets.

@tuki0918
Last active August 29, 2015 14:08
Show Gist options
  • Select an option

  • Save tuki0918/deb5c963d8a68cc93d18 to your computer and use it in GitHub Desktop.

Select an option

Save tuki0918/deb5c963d8a68cc93d18 to your computer and use it in GitHub Desktop.
CakePHP Settings
[submodule "app/Plugin/DebugKit"]
path = app/Plugin/DebugKit
url = https://github.com/cakephp/debug_kit.git
[submodule "app/Plugin/Phpunit"]
path = app/Plugin/Phpunit
url = https://github.com/dereuromark/cakephp-phpunit
[submodule "app/Plugin/Migrations"]
path = app/Plugin/Migrations
url = https://github.com/CakeDC/migrations.git
$ git submodule add https://github.com/cakephp/debug_kit.git app/Plugin/DebugKit
$ git submodule add https://github.com/dereuromark/cakephp-phpunit app/Plugin/Phpunit
$ git submodule add https://github.com/CakeDC/migrations.git app/Plugin/Migrations
$ berks install
$ vagrant up
$ vagrant ssh
$ sudo pecl install xdebug
$ apt-get install php5-dev

# You should add "extension=xdebug.so" to php.ini
$ sudo vi /etc/php5/fpm/php.ini
$ exit;
$ vagrant reload

PHPUnit Enable

# app/Config/bootstrap.php
CakePlugin::load('Phpunit');

or

CakePlugin::loadAll();
# vagrant ssh ?
$ Console/cake Phpunit.Phpunit install

Welcome to CakePHP v2.5.5 Console
---------------------------------------------------------------
App : app
Path: /vagrant_data/sandbox/app/
---------------------------------------------------------------
Installing PHPUnit 3.7 ...
1. /app/Vendor/
2. /vendors/
Select VENDOR path to install into (q/1/2) 
[q] > 2

Sequel Pro Vagrant Connection example

alt text

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment