This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace Dcwroc\TaskBundle\Entity; | |
class Task | |
{ | |
private $name; | |
private $dueDate; | |
private $completed = false; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
CWD=$(pwd) | |
STATUS=0 | |
echo "Running PHPSpec and PHPCS" | |
if [ -f $CWD/bin/phpspec ] | |
then | |
$CWD/bin/phpspec run --quiet |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
VAGRANTFILE_API_VERSION = "2" | |
digital_ocean_client_id = '' | |
digital_ocean_api_key = '' | |
Vagrant.require_plugin "vagrant-librarian-chef" | |
Vagrant.require_plugin "vagrant-omnibus" | |
Vagrant.require_plugin "vagrant-vbguest" | |
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config| |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
if [ -f ./bin/phpspec ] | |
then | |
./bin/phpspec run --quiet | |
if [ $? -ne 0 ] | |
then | |
echo "PHPSpec has failed - commit aborted" | |
return 1 | |
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
if [ -f ./bin/phpspec ] | |
then | |
./bin/phpspec run --quiet | |
if [ $? -ne 0 ] | |
then | |
echo "PHPSpec has failed - commit aborted" | |
return 1 | |
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* @Given /^I am logged in as a "([^"]*)"$/ | |
*/ | |
public function iAmLoggedInAsA($role) | |
{ | |
$firewall = 'secured_area'; | |
$session = $this->getContainer()->get('session'); | |
$user = $this->getUser(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<VirtualHost *:80> | |
DocumentRoot /mnt/project/web | |
RewriteEngine On | |
RewriteCond %{DOCUMENT_ROOT}/$1 !-f | |
RewriteRule ^/direcory/(.*)$ /direcory/app_dev.php [QSA,L,PT] | |
Alias /direcory /mnt/project/web |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
require_once __DIR__.'/vendor/autoload.php'; | |
use Symfony\Component\Console\Application; | |
use Cakper\YourBundle\Command\YourCommand; | |
$application = new Application(); | |
$application->add(new YourCommand); | |
$application->run(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"require": { | |
"symfony/console": "*", | |
"symfony/filesystem": "*" | |
}, | |
"minimum-stability": "stable", | |
"autoload": { | |
"psr-0": { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
require_once dirname(__DIR__).'/../../../../app/AppKernel.php'; | |
/** | |
* Test case class helpful with Entity tests requiring the database interaction. | |
* For regular entity tests it's better to extend standard \PHPUnit_Framework_TestCase instead. | |
*/ | |
abstract class KernelAwareTest extends \PHPUnit_Framework_TestCase | |
{ |