File tree Expand file tree Collapse file tree 1 file changed +35
-0
lines changed
tests/unit/DocBlock/Tags/Factory Expand file tree Collapse file tree 1 file changed +35
-0
lines changed Original file line number Diff line number Diff line change 1515
1616use phpDocumentor \Reflection \DocBlock \Description ;
1717use phpDocumentor \Reflection \DocBlock \Tags \Param ;
18+ use phpDocumentor \Reflection \Fqsen ;
19+ use phpDocumentor \Reflection \PseudoTypes \IntegerValue ;
20+ use phpDocumentor \Reflection \PseudoTypes \StringValue ;
21+ use phpDocumentor \Reflection \Types \Compound ;
1822use phpDocumentor \Reflection \Types \Context ;
1923use phpDocumentor \Reflection \Types \Integer ;
2024use phpDocumentor \Reflection \Types \Mixed_ ;
25+ use phpDocumentor \Reflection \Types \Object_ ;
2126use phpDocumentor \Reflection \Types \String_ ;
2227
2328final class ParamFactoryTest extends TagFactoryTestCase
@@ -87,6 +92,36 @@ public function paramInputProvider(): array
8792 false
8893 ),
8994 ],
95+ [
96+ '@param \'GET \'|SomeClass $arg My Description ' ,
97+ new Param (
98+ 'arg ' ,
99+ new Compound (
100+ [
101+ new StringValue ('GET ' ),
102+ new Object_ (new Fqsen ('\SomeClass ' ))
103+ ]
104+ ),
105+ false ,
106+ new Description ('My Description ' ),
107+ false
108+ ),
109+ ],
110+ [
111+ '@param 8|SomeClass $arg My Description ' ,
112+ new Param (
113+ 'arg ' ,
114+ new Compound (
115+ [
116+ new IntegerValue (8 ),
117+ new Object_ (new Fqsen ('\SomeClass ' ))
118+ ]
119+ ),
120+ false ,
121+ new Description ('My Description ' ),
122+ false
123+ ),
124+ ],
90125 ];
91126 }
92127}
You can’t perform that action at this time.
0 commit comments