Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

[DCOM-21] Fixing issue with stripped tags

  • Loading branch information...
commit df50f65ee707bb148682232c516d5168cf46d987 1 parent 3066c51
@jwage jwage authored
View
3  lib/Doctrine/Common/Annotations/Parser.php
@@ -43,8 +43,7 @@ class Parser
* @var array
*/
private static $strippedTags = array(
- "{@internal", "{@inheritdoc", "{@link", "@param", "@author", "@return",
- "@since", "@var", "@see", "@deprecated", "@copyright"
+ "{@internal", "{@inheritdoc", "{@link"
);
/**
View
20 tests/Doctrine/Tests/Common/Annotations/AnnotationReaderTest.php
@@ -137,6 +137,16 @@ public function testCustomAnnotationCreationFunction()
$this->assertEquals('hello', $annot->getDummyValue());
}
+ public function testNonAnnotationProblem()
+ {
+ $reader = new AnnotationReader(new \Doctrine\Common\Cache\ArrayCache);
+ $reader->setDefaultAnnotationNamespace('Doctrine\Tests\Common\Annotations\\');
+
+ $class = new ReflectionClass('Doctrine\Tests\Common\Annotations\DummyClassNonAnnotationProblem');
+ $annotations = $reader->getPropertyAnnotations($class->getProperty('foo'));
+ $this->assertNotEmpty($annotations);
+ }
+
public function createAnnotationReader()
{
$reader = new AnnotationReader(new \Doctrine\Common\Cache\ArrayCache);
@@ -245,4 +255,14 @@ class DummyClassPropertySyntaxError
* @DummyAnnotation(@)
*/
public $foo;
+}
+
+class DummyClassNonAnnotationProblem
+{
+ /**
+ * @DummyAnnotation
+ *
+ * @var \Test
+ */
+ public $foo;
}
Please sign in to comment.
Something went wrong with that request. Please try again.