mirror of
https://github.com/yiisoft/yii2.git
synced 2025-11-03 05:48:11 +08:00
Fix codestyle in build and tests (#20586)
This commit is contained in:
@ -51,13 +51,17 @@ class ViewTest extends TestCase
|
||||
$view = new View();
|
||||
|
||||
$exceptionViewFile = $this->testViewPath . DIRECTORY_SEPARATOR . 'exception.php';
|
||||
file_put_contents($exceptionViewFile, <<<'PHP'
|
||||
file_put_contents(
|
||||
$exceptionViewFile,
|
||||
<<<'PHP'
|
||||
<h1>Exception</h1>
|
||||
<?php throw new Exception('Test Exception'); ?>
|
||||
PHP
|
||||
);
|
||||
);
|
||||
$normalViewFile = $this->testViewPath . DIRECTORY_SEPARATOR . 'no-exception.php';
|
||||
file_put_contents($normalViewFile, <<<'PHP'
|
||||
file_put_contents(
|
||||
$normalViewFile,
|
||||
<<<'PHP'
|
||||
<h1>No Exception</h1>
|
||||
PHP
|
||||
);
|
||||
@ -82,7 +86,9 @@ PHP
|
||||
Yii::setAlias('@theme', $this->testViewPath . '/theme1');
|
||||
|
||||
$baseView = "{$this->testViewPath}/theme1/base.php";
|
||||
file_put_contents($baseView, <<<'PHP'
|
||||
file_put_contents(
|
||||
$baseView,
|
||||
<<<'PHP'
|
||||
<?php
|
||||
echo $this->render("sub");
|
||||
?>
|
||||
@ -90,7 +96,7 @@ PHP
|
||||
);
|
||||
|
||||
$subView = "{$this->testViewPath}/sub.php";
|
||||
$subViewContent = "subviewcontent";
|
||||
$subViewContent = 'subviewcontent';
|
||||
file_put_contents($subView, $subViewContent);
|
||||
|
||||
$view->theme = new Theme([
|
||||
|
||||
Reference in New Issue
Block a user