php-parser/test/code/formatPreservation/inlineHtml.test

54 lines
596 B
Plaintext
Raw Normal View History

2017-12-24 18:04:51 +01:00
Handling of inline HTML
-----
<?php
function test() {
?>Foo<?php
}
-----
$stmts[0]->setAttribute('origNode', null);
-----
<?php
function test()
{
?>Foo<?php
2017-12-26 15:07:16 +01:00
}
-----
<?php
function test() {
foo();
?>Bar<?php
baz();
}
-----
// TODO Fix broken result
$stmts[0]->stmts[2] = $stmts[0]->stmts[1];
-----
<?php
function test() {
foo();
?>Bar<?php
Bar
}
-----
<?php
function test() {
foo();
?>Bar<?php
baz();
}
-----
// TODO Fix broken result
$stmts[0]->stmts[1] = $stmts[0]->stmts[2];
-----
<?php
function test() {
foo();<?php
baz();
baz();
2017-12-24 18:04:51 +01:00
}