File tree Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change 9
9
10
10
namespace SymfonyDocsBuilder \Tests ;
11
11
12
+ use Doctrine \RST \Builder ;
12
13
use Doctrine \RST \Configuration ;
13
14
use Doctrine \RST \Parser ;
14
15
use Gajus \Dindent \Indenter ;
@@ -90,9 +91,10 @@ public function testParseUnitBlock(string $blockName)
90
91
$ configuration = new Configuration ();
91
92
$ configuration ->setCustomTemplateDirs ([__DIR__ .'/Templates ' ]);
92
93
93
- $ parser = new Parser (
94
- KernelFactory::createKernel ($ this ->createBuildConfig (sprintf ('%s/fixtures/source/blocks ' , __DIR__ )))
95
- );
94
+ $ kernel = KernelFactory::createKernel ($ this ->createBuildConfig (sprintf ('%s/fixtures/source/blocks ' , __DIR__ )));
95
+ // necessary because this initializes some listeners on the kernel
96
+ $ builder = new Builder ($ kernel );
97
+ $ parser = new Parser ($ kernel );
96
98
97
99
$ sourceFile = sprintf ('%s/fixtures/source/blocks/%s.rst ' , __DIR__ , $ blockName );
98
100
You can’t perform that action at this time.
0 commit comments