InlineCss = new InlineCssLib(); $res = App::import('Vendor', 'Tools.CssToInlineStyles', array('file' => 'CssToInlineStyles' . DS . 'CssToInlineStyles.php')); $this->skipIf(!$res); parent::setUp(); } public function testProcess() { $res = $this->InlineCss->process($this->testHtml); $this->debug($this->testHtml); $this->debug($res); } public function testProcessAlternativeEngine() { //TODO } public function testProcessPlainPiece() { $html = 'blabla

Sample Page Title

Bacon ipsum dolor sit amet in cow elit, in t-bone qui meatloaf corned beef aute ullamco minim. Consequat swine short ribs pastrami jerky.

Some small note!

bla'; $res = $this->InlineCss->process($html); $this->debug($html); $this->debug($res); } public $testHtml = ' Example

Sample Page Title

Bacon ipsum dolor sit amet in cow elit, in t-bone qui meatloaf corned beef aute ullamco minim. Consequat swine short ribs pastrami jerky.

Some small note!

'; public function testProcessUtf8() { $this->skipIf(version_compare(PHP_VERSION, '5.4.0') < 0, 'UTF8 only works with PHP5.4 and above'); $html = 'チェック

チェック

チェックインは15:00以降です。アーリーチェックインはリクエストにて

チェック\'foo\'

bla'; $res = $this->InlineCss->process($html); $this->debug($html); $this->debug($res); $this->assertTextStartsWith('チェック', $res); } }