|
|
|
@ -48,8 +48,7 @@ class AssetBundleTest extends \yiiunit\TestCase
|
|
|
|
|
$this->assertTrue($view->assetBundles['yiiunit\\framework\\web\\TestSimpleAsset'] instanceof AssetBundle); |
|
|
|
|
|
|
|
|
|
$expected = <<<EOF |
|
|
|
|
123<script src="/js/jquery.js"></script> |
|
|
|
|
4 |
|
|
|
|
123<script src="/js/jquery.js"></script>4 |
|
|
|
|
EOF; |
|
|
|
|
$this->assertEquals($expected, $view->renderFile('@yiiunit/data/views/rawlayout.php')); |
|
|
|
|
} |
|
|
|
@ -69,10 +68,8 @@ EOF;
|
|
|
|
|
$this->assertTrue($view->assetBundles['yiiunit\\framework\\web\\TestAssetLevel3'] instanceof AssetBundle); |
|
|
|
|
|
|
|
|
|
$expected = <<<EOF |
|
|
|
|
1<link href="/files/cssFile.css" rel="stylesheet"> |
|
|
|
|
23<script src="/js/jquery.js"></script> |
|
|
|
|
<script src="/files/jsFile.js"></script> |
|
|
|
|
4 |
|
|
|
|
1<link href="/files/cssFile.css" rel="stylesheet">23<script src="/js/jquery.js"></script> |
|
|
|
|
<script src="/files/jsFile.js"></script>4 |
|
|
|
|
EOF; |
|
|
|
|
$this->assertEquals($expected, $view->renderFile('@yiiunit/data/views/rawlayout.php')); |
|
|
|
|
} |
|
|
|
@ -129,25 +126,20 @@ EOF;
|
|
|
|
|
$expected = <<<EOF |
|
|
|
|
1<link href="/files/cssFile.css" rel="stylesheet"> |
|
|
|
|
<script src="/js/jquery.js"></script> |
|
|
|
|
<script src="/files/jsFile.js"></script> |
|
|
|
|
234 |
|
|
|
|
<script src="/files/jsFile.js"></script>234 |
|
|
|
|
EOF; |
|
|
|
|
break; |
|
|
|
|
case View::POS_BEGIN: |
|
|
|
|
$expected = <<<EOF |
|
|
|
|
1<link href="/files/cssFile.css" rel="stylesheet"> |
|
|
|
|
2<script src="/js/jquery.js"></script> |
|
|
|
|
<script src="/files/jsFile.js"></script> |
|
|
|
|
34 |
|
|
|
|
1<link href="/files/cssFile.css" rel="stylesheet">2<script src="/js/jquery.js"></script> |
|
|
|
|
<script src="/files/jsFile.js"></script>34 |
|
|
|
|
EOF; |
|
|
|
|
break; |
|
|
|
|
default: |
|
|
|
|
case View::POS_END: |
|
|
|
|
$expected = <<<EOF |
|
|
|
|
1<link href="/files/cssFile.css" rel="stylesheet"> |
|
|
|
|
23<script src="/js/jquery.js"></script> |
|
|
|
|
<script src="/files/jsFile.js"></script> |
|
|
|
|
4 |
|
|
|
|
1<link href="/files/cssFile.css" rel="stylesheet">23<script src="/js/jquery.js"></script> |
|
|
|
|
<script src="/files/jsFile.js"></script>4 |
|
|
|
|
EOF; |
|
|
|
|
break; |
|
|
|
|
} |
|
|
|
|