Mercurial > hg > isophonics-drupal-site
comparison vendor/nikic/php-parser/test/PhpParser/PrettyPrinterTest.php @ 16:c2387f117808
Routine composer update
author | Chris Cannam |
---|---|
date | Tue, 10 Jul 2018 15:07:59 +0100 |
parents | 5fb285c0d0e3 |
children | 129ea1e6d783 |
comparison
equal
deleted
inserted
replaced
15:e200cb7efeb3 | 16:c2387f117808 |
---|---|
207 $prettyPrinter = new PrettyPrinter\Standard; | 207 $prettyPrinter = new PrettyPrinter\Standard; |
208 $prettyPrinter->prettyPrint($stmts); | 208 $prettyPrinter->prettyPrint($stmts); |
209 } | 209 } |
210 | 210 |
211 /** | 211 /** |
212 * @expectedException \LogicException | |
213 * @expectedExceptionMessage Cannot directly print EncapsedStringPart | |
214 */ | |
215 public function testPrettyPrintEncapsedStringPart() { | |
216 $expr = new Node\Scalar\EncapsedStringPart('foo'); | |
217 $prettyPrinter = new PrettyPrinter\Standard; | |
218 $prettyPrinter->prettyPrintExpr($expr); | |
219 } | |
220 | |
221 /** | |
212 * @dataProvider provideTestFormatPreservingPrint | 222 * @dataProvider provideTestFormatPreservingPrint |
213 * @covers \PhpParser\PrettyPrinter\Standard<extended> | 223 * @covers \PhpParser\PrettyPrinter\Standard<extended> |
214 */ | 224 */ |
215 public function testFormatPreservingPrint($name, $code, $modification, $expected, $modeLine) { | 225 public function testFormatPreservingPrint($name, $code, $modification, $expected, $modeLine) { |
216 $lexer = new Lexer\Emulative([ | 226 $lexer = new Lexer\Emulative([ |