#Motive
- Motive is a top secret project
- Motive is not a real name.
Environment Setup
Required Software
Install Apache and PHP
Install Neo4j
Install Composer
Install Slim PHP / Neo4jPHP
Download Motive
Apache Setup
Enable URL Rewrite
PHP Unit Tests
May already be installed, if not, please use your OS standard way of installing software packages.
##Neo4jCan be acquired from: http://www.neo4j.org/download Once installed, start the Neo4j server: sudo {NEO4J Home}/bin/neo4j start
##ComposerMotive uses PHP Composer to download and initialize PHP libraries.
Install PHP Composer for your operating system: http://getcomposer.org/download/
##Slim PHP / Neo4jPHP ##Download Motivegit clone [email protected]:emuneee/motive.git
Run PHP composer to download Neo4jPHP, Slim PHP, and PHPSec libraries
From /motive/api run:
php composer.phar install
-or-
composer install
This step is necessary for us to expose our API.
mkdir /etc/apache2/mods-enabled #If directory does not already exist
cd /etc/apache2/mods-enabled
ln -s ../mods-available/rewrite.load rewrite.load
- Visit http://localhost/index.php. If the Slim PHP page loads, your setup is correct. If not, check your Apache logs for errors.
For unit testing, we will be using the PHPUnit test framework. It can be acquired here
Mac OS X (more or less) - http://www.newmediacampaigns.com/page/install-pear-phpunit-xdebug-on-macosx-snow-leopard
Linux - http://www.giocc.com/installing-phpunit-on-ubuntu-11-04-natty-narwhal.html
##Running Unit Tests
Unit tests can be using the following command
phpunit --verbose NameOfTestHere