sudo apt-get install php5 php5-mysql php5-intl php5-curl php5-xdebug php5-gd php-apc mysql-server apache2
sudo apt-get install git
sudo apt-get install default-jre
# https://github.com/symfony/flex/issues/251#issuecomment-364113857 | |
# emmanuelballery says: | |
I'm currently using a bash script to solve this "ENV vars in test" problem: | |
```bash | |
set -o allexport # export all defined variables | |
source .env # load dev parameters | |
source .env.test # override with test parameters (only those needed) |
<?php | |
namespace App\Api; | |
class ApiResponse | |
{ | |
private $message; | |
private $data; | |
private $errors; | |
private $statusCode; |
<?php | |
namespace Acme\Bundle\ProjectBundle\Entity; | |
use Doctrine\Common\Collections\ArrayCollection; | |
use Doctrine\ORM\Mapping as ORM; | |
use Acme\Bundle\ProjectBundle\Entity\ProjectHasMedia; | |
/** | |
* Project |
<?php | |
namespace Tests; | |
class JuniorTest extends \PHPUnit_Framework_TestCase | |
{ | |
public function testFn() | |
{ | |
$a3 = ['s1' => ['s2' => ['s3' => 123]]]; | |
$b4 = ['s1' => ['s2' => ['s3' => ['s4' => 777]]]]; |
<?php | |
namespace AppBundle\Command; | |
use AppBundle\Entity\Event; | |
use Debril\RssAtomBundle\Protocol\Parser\Item; | |
use Symfony\Bundle\FrameworkBundle\Command\ContainerAwareCommand; | |
use Symfony\Component\Console\Input\InputInterface; | |
use Symfony\Component\Console\Output\OutputInterface; |
#!/bin/sh | |
# setup project | |
bin/setup | |
# clean build dir | |
rm -rf build/ | |
# prepare logs dir | |
mkdir -p build/logs/behat |
<?php | |
namespace Predanie\ArchiveBundle\Consumer; | |
use Doctrine\ORM\EntityManager; | |
use FFMpeg\FFMpeg; | |
use FFMpeg\Format\Video\Ogg; | |
use Monolog\Logger; | |
use OldSound\RabbitMqBundle\RabbitMq\ConsumerInterface; | |
use PhpAmqpLib\Message\AMQPMessage; |
Коды ошибок соответствуют стандарту RFC 7231 если не описаны иначе.
status_code: 200 – OK 400 – Bad request 404 – Not Found
Ant-Task which runs behat: | |
<?xml version="1.0" encoding="UTF-8"?> | |
<project name="Foo" default="build" basedir="."> | |
.... | |
<target name="behat"> | |
<exec dir="${basedir}/" executable="php" failonerror="true"> |