Magento 2 Documentation  2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
JShrinkTest.php
Go to the documentation of this file.
1 <?php
7 
8 class JShrinkTest extends \PHPUnit\Framework\TestCase
9 {
10  public function testMinify()
11  {
12  $content = file_get_contents(__DIR__ . '/../../_files/js/original.js');
13  $minifier = new \Magento\Framework\Code\Minifier\Adapter\Js\JShrink();
14  $actual = $minifier->minify($content);
15  $expected = "var one='one';var two='two';";
16  $this->assertEquals($expected, $actual);
17  }
18 }
defined('TESTS_BP')||define('TESTS_BP' __DIR__
Definition: _bootstrap.php:60