Merge pull request #758 from dunglas/master

Fix tests related to DunglasApiBundle
This commit is contained in:
William Durand 2015-11-22 08:22:33 +01:00
commit 4fad200d7b
8 changed files with 3456 additions and 3462 deletions

View File

@ -98,7 +98,7 @@ class DunglasApiParser implements ParserInterface
$data = array();
foreach ($classMetadata->getAttributes() as $attributeMetadata) {
if (
($attributeMetadata->isReadable() && self::OUT_PREFIX === $io) ||
(!$attributeMetadata->isIdentifier() && $attributeMetadata->isReadable() && self::OUT_PREFIX === $io) ||
($attributeMetadata->isWritable() && self::IN_PREFIX === $io)
) {
$data[$attributeMetadata->getName()] = $this->parseAttribute($resource, $attributeMetadata, $io);

View File

@ -19,10 +19,15 @@ class Popo
/**
* @var int
*/
public $id;
private $id;
/**
* @var string
*/
public $foo;
public function getId()
{
return $this->id;
}
}

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -31,8 +31,6 @@ class DunglasApiParserTest extends WebTestCase
public function testParser()
{
$this->markTestSkipped('There is an issue because of DunglasApiBundle');
$container = $this->getContainer();
$parser = $container->get('nelmio_api_doc.parser.dunglas_api_parser');

View File

@ -34,9 +34,11 @@
"symfony/form": "~2.3",
"symfony/finder": "~2.3",
"symfony/serializer": "~2.7",
"doctrine/orm": "~2.3",
"doctrine/doctrine-bundle": "~1.5",
"friendsofsymfony/rest-bundle": "~1.0",
"jms/serializer-bundle": ">=0.11",
"dunglas/api-bundle": "~1.0",
"dunglas/api-bundle": "~1.0@dev",
"sensio/framework-extra-bundle": "~3.0",
"symfony/phpunit-bridge": "~2.7"
},