DotsUnited\BundleFu\Tests\Filter\ClosureCompilerServiceFilterTest::testFilterShouldCompileContents PHP Method

testFilterShouldCompileContents() public method

    public function testFilterShouldCompileContents()
    {
        $filter = new ClosureCompilerServiceFilter();
        $uncompiled = "function js_1() { alert('hi')};\n\n// this is a function\nfunction func() {\n  alert('hi')\n  return true\n}\n\nfunction func() {\n  alert('hi')\n  return true\n}\n";
        $compiled = 'function js_1(){alert("hi")}function func(){alert("hi");return!0}function func(){alert("hi");return!0};';
        $this->assertEquals($compiled, trim($filter->filter($uncompiled)));
    }