Browse Source

skip tests if no engine is present

euromark 12 years ago
parent
commit
83b490bee6
2 changed files with 8 additions and 0 deletions
  1. 1 0
      Lib/InlineCssLib.php
  2. 7 0
      Test/Case/Lib/InlineCssLibTest.php

+ 1 - 0
Lib/InlineCssLib.php

@@ -5,6 +5,7 @@
  * Useful for sending HTML emails
  *
  * Note: requires vendors CssToInline or emogrifier!
+ * Default engine: CssToInline
  *
  * @author Mark Scherer
  * @copyright Mark Scherer

+ 7 - 0
Test/Case/Lib/InlineCssLibTest.php

@@ -8,6 +8,9 @@ class InlineCssLibTest extends MyCakeTestCase {
 		//Configure::write('InlineCss.engine', 'cssToInline');
 		$this->InlineCss = new InlineCssLib();
 
+		$res = App::import('Vendor', 'CssToInline', array('file' => 'css_to_inline_styles'.DS.'css_to_inline_styles.php'));
+		$this->skipIf(!$res);
+
 		parent::setUp();
 	}
 
@@ -17,6 +20,10 @@ class InlineCssLibTest extends MyCakeTestCase {
 		$this->debug($res);
 	}
 
+	public function testProcessAlternativeEngine() {
+		//TODO
+	}
+
 	public function testProcessPlainPiece() {
 		$html = 'blabla
 	<style>